ClientHelper
Client helper class
| since |
1.7.0 |
|---|---|
| package |
Joomla CMS |
Methods
getCredentials
Method to return the array of client layer configuration options
getCredentials( client, force = false) : mixed||string|int
| since |
1.7.0 |
|---|
Arguments
- client
stringClient name, currently only 'ftp' is supported- force
boolForces re-creation of the login credentials. Set this to true if login credentials in the session storage have changed
Response
array<string|int, mixed>Client layer configuration options, consisting of at least
these fields: enabled, host, port, user, pass, root
hasCredentials
Method to determine if client login credentials are present
hasCredentials( client) :
| since |
1.7.0 |
|---|
Arguments
- client
stringClient name, currently only 'ftp' is supported
Response
boolTrue if login credentials are available
setCredentials
Method to set client login credentials
setCredentials( client, user, pass) :
| since |
1.7.0 |
|---|
Arguments
- client
stringClient name, currently only 'ftp' is supported- user
stringUsername- pass
stringPassword
Response
boolTrue if the given login credentials have been set and are valid
setCredentialsFromRequest
Determine whether input fields for client settings need to be shown
setCredentialsFromRequest( client) :
If valid credentials were passed along with the request, they are saved to the session. This functions returns an exception if invalid credentials have been given or if the connection to the server failed for some other reason.
| since |
1.7.0 |
|---|---|
| throws |
|
Arguments
- client
stringThe name of the client.
Response
boolTrue if credentials are present