PDA

View Full Version : Not working actually



ESKosters
02-05-2006, 07:13 AM
Hello all i have quite a problem, i made a totally order system myself no problems with that all works fine but now i want to create users in the administration. So i dont have to go to directadmin first. I decided to work with the API coding. Here is what i made.

webhosting.php - To get the pages all the $web_ does work also $email works because i tested it with some prints.


<?php
if($web_pakket == "Reseller1" || $web_pakket == "Reseller2" || $web_pakket == "Reseller3"){
include 'DA/reseller.php';
}
else{
include 'DA/user.php';
}
?>


reseller.php

<?php
include '../include/database.php';
include 'httpsocket.php';

$Socket = new HTTPSocket;
$Socket->connect('$da_ip','$da_poort');
$Socket->set_login('$da_gebruiker','$da_wachtwoord');
$Socket->query('/CMD_API_ACCOUNT_RESELLER',
array(
'username' => '$web_gebruikersnaam',
'email' => '$email',
'passwd' => '$web_wachtwoord',
'passwd2' => '$web_wachtwoord',
'domain' => '$web_domein',
'package' => 'reseller',
'ip' => 'shared',
'notify' => 'yes',
'action' => 'create',
'add' => 'Submit'
));
?>

user.php

<?php
include '../include/database.php';
include 'httpsocket.php';

$Socket = new HTTPSocket;
$Socket->connect('$da_ip','$da_poort');
$Socket->set_login('$da_gebruiker','$da_wachtwoord');
$Socket->query('/CMD_API_ACCOUNT_USER',
array(
'username' => '$web_gebruikersnaam',
'email' => '$email',
'passwd' => '$web_wachtwoord',
'passwd2' => '$web_wachtwoord',
'domain' => '$web_domein',
'package' => 'small',
'ip' => 'shared',
'notify' => 'yes',
'action' => 'create',
'add' => 'Submit'
));
?>

It just wont create the thing he does login but doenst make any account.. any idea? I had user working once but remade it and didnt work any more :p but Reseller i never got worked.

jmstacey
02-12-2006, 01:00 PM
This is a little old, but is there any return?

ESKosters
02-12-2006, 01:02 PM
ive got it fixed if you want i could post the script but it did it on another way though