@Sportbikeworld : I don't think it is possible to grab the data you want with one query. I'd suggest to give up and use multiple webqueries to compile this data. I think you don't want to increase the query count of your webtemplate with a single query for each forum but this shouldn't cause a big performance problem so try it.
@Spinball : Webtemplate PHP parsing is exactly same as vbulletin's PHP parsing in phpinclude template and you are not able to use the other webtemplate features in a PHP parsed webtemplate like automatic header/footer inclusion. However you should consider:
a) If your PHP code is basic : Make your webtemplate parsing TXT or HTML (instead of PHP) and run your PHP code inside PHP parsed template of webtemplate.
b) If your PHP code is advanced : Grab vb header and footer inside your PHP code with PHP commands as well like:
eval('$headinclude = "' . fetch_template('headinclude') . '";');
eval('$header = "' . fetch_template('header') . '";');
eval('$footer = "' . fetch_template('footer') . '";');
|