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.
Thread Tools Display Modes
Old 28th November 2011, 16:18
caudatus caudatus is offline
Junior Member
Join Date: Jun 2009
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default *.list.php: how get records from an SQL query instead of a table

Dear Till!

It's the first time when I can say a big thank for this great admin sw, "ispconfig"!

Could You tell me,
that Is it possible in *.list.php files to get records from an SQL select query instead of a simple table ?

To define the record source by default the form (with an example table) is:

$liste["table"] = "mail_forwarding";

It would be nice to create merged lists, for example primary and secondary dns zones in one list.

Thank You very much!

Reply With Quote
Sponsored Links
Old 28th November 2011, 16:33
till till is offline
Super Moderator
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 37,015
Thanks: 840
Thanked 5,651 Times in 4,461 Posts

Each list object in ISPConfig is based on the class listform_actions. The listform actions can be found in interface/lib/classes/listform_actions.inc.php file. This class contains a function named getQueryString() which returns the sql string that is used to display the list. To show lists with a more complex sql syntax, you can override the function getQueryString() in your custom list file.



class list_action extends listform_actions {
	function getQueryString(){
                $my_sql_query = "SELECT * FROM a,b WHERE ......";
                return $my_sql_query;


$list = new list_action;
Till Brehm
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote


list.php, sql, table

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
server.sh not starting up tuxillo Installation/Configuration 8 31st December 2010 15:14
Step by step email setup for domain & clients aurasdoom Installation/Configuration 17 19th January 2010 13:25
sarg issue while generating reports for squid mail4vij Server Operation 3 31st December 2009 14:12
phpmyadmin error lifeisboost Installation/Configuration 9 14th August 2008 20:19
Rejected e-mail (unknown user) w/Postfix doronkeller HOWTO-Related Questions 9 27th January 2008 21:09

All times are GMT +2. The time now is 11:56.

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