error add_user remoting framework

Discussion in 'General' started by mccharlet, Mar 27, 2007.

  1. mccharlet

    mccharlet Member HowtoForge Supporter

    Hi,

    When i add a user, this user is create but my script stop with this error

    Error: HTTP Error: no data present after HTTP headers

    Thanks :confused:
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    Please make sure that your php has curl compiled in.
     
  3. mccharlet

    mccharlet Member HowtoForge Supporter

    Yes, php-curl is installed.
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    Then it is most likely a error in your script, I can not tell you something about it without knowing the script.
     
  5. mccharlet

    mccharlet Member HowtoForge Supporter

    Hi

    this is my script.

    The error is return after the user creation

    <?php

    include("soap.lib.php");
    // Insert here your 42go Server
    $ip_server = "192.168.1.10";
    $server_url = "https://$ip_server:81";

    // creating object for SoapClient
    $soapclient = new soapclient($server_url.'/remote/index.php');

    // Username and Password of the remoting user (not identical
    // with the user to log into the web interface!)

    $parameters = array('user' => 'remote',
    'pass' => 'remote');

    // Login into 42go Server
    $session_id = $soapclient->call('login',$parameters);

    // Error Check
    if($err = $soapclient->getError()) die("Error: ".$err);

    $params = array ( 'sid' => $session_id,
    'module' => 'kunde',
    'function' => 'kunde_add',
    'params' => array ( reseller_title => 'ateliern',
    kunde_title => 'monclient',
    kunde_anrede => 'Herr', // Herr, Frau, Firma
    kunde_firma => 'Kunde6',
    kunde_vorname => 'Tom',
    kunde_name => 'Sawyer',
    kunde_strasse => 'Hauptstr. 1',
    kunde_plz => '12345',
    kunde_ort => 'Hauptstadt',
    kunde_land => 'Deutschland',
    kunde_telefon => '0511 5469766',
    kunde_fax => '0511 9799655',
    kunde_email => '[email protected]',
    kunde_internet => 'http://www.kunde6.tld',
    webadmin_user => 'kunde6',
    webadmin_passwort => 'kunde6',
    kunde_province => 'Niedersachsen'
    ));

    $kunde_id = $soapclient->call('service',$params);
    if($err = $soapclient->getError()) die("Error: ".$err);
    print_r($kunde_id);


    // 42go Server logout
    $soapclient->call('logout',array('sid' => $session_id));

    // Error Check
    if($err = $soapclient->getError()) die("Error: ".$err);

    echo "<br>Script end ...";




    ?>
     
  6. mccharlet

    mccharlet Member HowtoForge Supporter

    This error is returned by the sendHTTPS fonction on soa.lib.php

    are you an idea

    Thanks
     
  7. till

    till Super Moderator Staff Member ISPConfig Developer

    Your ISPConfig PHP is compiled with XML support, you installed the remoting framework, updated theioncube library if you dont use the ISPConfig dev version and created a remoting user?
     
  8. mccharlet

    mccharlet Member HowtoForge Supporter

    I did all that

    My script create the user and finish by this error
     

Share This Page