Hi dear friends!!!
I'm new in php and cPanel Developers.
I downloaded the file xmlapi.php and I'm having doubts.
What steps I can to implement this script on my system?
I'm doing authentication by hash. The user must be 'root' or it may be other?
I tried with root: hash_auth('root','chave');
but return "0 Access denied".
And I tried with other user and return '0 Sorry, that username is reserved.'
I can see this return because I put "echo" in a line of the xmlapi_query function, like below:
// perform simplexml transformation (array relies on this)
if ( ($this->output == 'simplexml') || $this->output == 'array') {
echo $response;//show access denied;
$response = simplexml_load_string($response, null, LIBXML_NOERROR | LIBXML_NOWARNING);
if (!$response){
error_log("Some error message here");
return;
}
if ( $this->debug ) {
error_log("SimpleXML var_dump:\n" . print_r($response, true));
}
}
I'm grateful and I'm sorry because I don't speak English very well.
I'm new in php and cPanel Developers.
I downloaded the file xmlapi.php and I'm having doubts.
What steps I can to implement this script on my system?
I'm doing authentication by hash. The user must be 'root' or it may be other?
I tried with root: hash_auth('root','chave');
but return "0 Access denied".
And I tried with other user and return '0 Sorry, that username is reserved.'
I can see this return because I put "echo" in a line of the xmlapi_query function, like below:
// perform simplexml transformation (array relies on this)
if ( ($this->output == 'simplexml') || $this->output == 'array') {
echo $response;//show access denied;
$response = simplexml_load_string($response, null, LIBXML_NOERROR | LIBXML_NOWARNING);
if (!$response){
error_log("Some error message here");
return;
}
if ( $this->debug ) {
error_log("SimpleXML var_dump:\n" . print_r($response, true));
}
}
I'm grateful and I'm sorry because I don't speak English very well.