Hi,

I've written a script which any server start or stop. It works!
Now I wanted that when I shut down the server, stop the auto start (set 0).
Unfortunately it does not work and there is a mistake.


Look:
PHP Code:
<?php

require_once('../include/libraries/TeamSpeak3/TeamSpeak3.php');

      
$server = array( 
              
"tsip" => "***********",
              
"ts_query_admin" => "serveradmin",
              
"ts_query_password" => "******",
              
"ts_query_port" => "10010",
          );
      
$value2 = array(
              
"virtualserver_port" => "3000",
      
      );

      try {
              
TeamSpeak3::init();
              
$ts3_VirtualServer TeamSpeak3::factory("serverquery://".$server["ts_query_admin"].":".$server["ts_query_password"]."@".$server["tsip"].":".$server["ts_query_port"]."");
              
$client $ts3_VirtualServer->serverStop('12');
                    
$ts3_VirtualServer->selectServer($value2['virtualserver_port'], 'port'true);
                    
$autostart_edit=$ts3->serverEdit(array('virtualserver_autostart'=>$value['auto']));
          
          } catch(
Exception $e) {
                   echo 
"Fehler!<br/>ErrorID: <b>"$e->getCode() ."</b>; Error Message: <b>"$e->getMessage() ."</b>;";
          }

?>
The script is based on the framework of @ScP

The Error: ErrorID: 0; Error Message: node method 'selectServer()' does not exist;

Can me someone help?

Thanks,

Pascal