Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > ISPConfig 3 > Developers' Forum

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 19th April 2012, 12:26
todx todx is offline
Member
 
Join Date: Apr 2012
Posts: 77
Thanks: 33
Thanked 6 Times in 5 Posts
Default List all websites via ISPConfig remote API

I'm assuming that when I access sites web_domain_list.php is executed?

How can I use that from ISPConfig remote API?

Anyway I'd like to list all website domain using ISPConfig remote API...
Reply With Quote
Sponsored Links
  #2  
Old 19th April 2012, 12:40
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 35,771
Thanks: 821
Thanked 5,331 Times in 4,183 Posts
Default

Please see remote API documnetation for a list of api functions, you find that in the remote_client/ API-docs/ folder of the ISPConfig tar.gz. All functions are described there incl. script examples.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
The Following 2 Users Say Thank You to till For This Useful Post:
david_hitt@lionlike.com (9th April 2014), feeninuoumn (5th May 2014)
  #3  
Old 19th April 2012, 12:47
todx todx is offline
Member
 
Join Date: Apr 2012
Posts: 77
Thanks: 33
Thanked 6 Times in 5 Posts
Default

I've found the example, but that only allows retrieving one website at a time by providing the id
Reply With Quote
  #4  
Old 19th April 2012, 13:18
todx todx is offline
Member
 
Join Date: Apr 2012
Posts: 77
Thanks: 33
Thanked 6 Times in 5 Posts
Default

Found a simple solution: =)

PHP Code:
$c=1;
while(
$domain_record $client->sites_web_domain_get($session_id$c)) {
     
var_dump($domain_record);
     
$c++;

Reply With Quote
  #5  
Old 9th April 2014, 01:54
david_hitt@lionlike.com david_hitt@lionlike.com is offline
Junior Member
 
Join Date: Feb 2011
Posts: 25
Thanks: 6
Thanked 4 Times in 4 Posts
 
Default Kinda late... but...

Till showed me this one:

Code:
$domain_record = $client->sites_web_domain_get($session_id, array('system_group' => 'client'.$client_id));
foreach ($domain_record as $domains) {
  echo $domains['domain']."<br>";
}
You can use "array('system_group' => 'client'.$client_id)" in place of $primary_id so it'll search the table field specified and match criteria.

I just so happen to store the client_id in the interfacing system so I pull client_id from my local database, concat with 'client' and search the web_domains using 'system_group' which equals clientX.
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Wong username or password using ISPConfig remote API todx General 1 19th April 2012 09:16
Ftp problems timeout reny2000 General 6 23rd December 2009 11:09
remote framwork with ispconfig 2.2.16 arnaud Installation/Configuration 2 3rd October 2007 10:08
HELP - websites gone in ispconfig itgroup Installation/Configuration 2 8th July 2007 10:23
Totally Confused?? :( kingtux Installation/Configuration 7 9th February 2006 22:14


All times are GMT +2. The time now is 01:52.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.