ClientHelper
Client helper class
| since |
1.7.0 |
|---|---|
| package |
Joomla CMS |
Methods
getCredentials
Method to return the array of client layer configuration options
getCredentials(string client, bool force = false) : array
| 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
arrayClient 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(string client) : bool
| 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(string client, string user, string pass) : bool
| 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(string client) : mixed
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
mixedTrue, if FTP settings; JError if using legacy tree.