Sunday, 15 August 2010

apache - ISPConfig SOAP Remote API add web domain with php enabled -



apache - ISPConfig SOAP Remote API add web domain with php enabled -

i using remote api of ispconfig create ispconfig user, web site , ftp user , working okay, creates ispconfig user, website , ftp user, can access them through ispconfig , ftp , web site works doesn't enable php if have activated on params.

here necessary code:

$domain = 'domain.example.com'; $params = array( 'domain' => $domain, 'ip_address' => '', 'type' => 'vhost', 'parent_domain_id' => 0, 'vhost_type' => '', 'hd_quota' => 100, 'traffic_quota' => 4000, 'cgi' => 'n', 'ssi' => 'n', 'suexec' => 'n', 'errordocs' => 1, 'is_subdomainwww' => 1, 'subdomain' => '', 'php' => 'y', /* activated nothing*/ 'ruby' => 'y', /*this activated , works*/ 'redirect_type' => '', 'redirect_path' => '', 'ssl' => 'n', 'ssl_state' => '', 'ssl_locality' => '', 'ssl_organisation' => '', 'ssl_organisation_unit' => '', 'ssl_country' => '', 'ssl_domain' => '', 'ssl_request' => '', 'ssl_cert' => '', 'ssl_bundle' => '', 'ssl_action' => '', 'stats_password' => '', 'stats_type' => 'webalizer', 'allow_override' => 'all', 'apache_directives' => '', 'php_open_basedir' => '/', 'custom_php_ini' => '', 'backup_interval' => '', 'backup_copies' => 1, 'active' => 'y', 'traffic_quota_lock' => 'n' );

i don't think need write in 'custom_php_ini' , correct?

i have class utilize ispconfig, , method create website is:

public function addwebsite($clientid, $params) { $params['server_id'] = $this->server_id; utf8_encode_array($params,'utf8_decode_array'); seek { homecoming $this->soapclient->sites_web_domain_add($this->session_id, $clientid, $params, $readonly = false); } grab (soapfault $e) { throw new ispcfgexception($e->getmessage(), 500); } }

in creation of ispconfig user set param ''web_php_options' => 'mod' doesn't work...

can help me? give thanks much help in advance!

i think there parameter don't know indicate php engine don´t find right documentation.

i solved it.

i looking @ documentation provided when download zip the website , can here.

if @ documentation says param 'php' enum values 'n' , 'y' works ipconfig version 2. in ispconfig3 can edit php engine (mod-php, cgi...) not enable it.

so works writing in $params:

'php' => 'mod',

php apache website webserver web-hosting

No comments:

Post a Comment