PDA

View Full Version : code in phpinclude....


drives fast
04-09-2003, 04:43 PM
I am trying to display the forum title, number of threads and forum discription of a specific forum (id=150) on a non vb page that I have integrated into vb and has isn't own template.

problem is...I don't know what to put in the phpinclude template to allow me to do this.

can anyone help me?

thank you

filburt1
04-09-2003, 04:55 PM
If it's a non-vB page then there's nothing you can easily do because phpinclude is only executed on vB pages.

drives fast
04-09-2003, 05:07 PM
it is integrated into vbulletin

here is the php for the page:
<?php
error_reporting(7);

$templatesused='classifieds';

require('./global.php');

if ($bbuserinfo[userid]==0) {
show_nopermission();
}

$bbusername = $bbuserinfo[username];

eval("dooutput(\"".gettemplate('classifieds')."\");");

?>

and it has its own template called "classifieds"

can there not be code written to the phpinclude template to draw the forumtitle,threadcount and forumdescription of forumid 150 and display that info in the classifieds template with a call like $forum150 ?

drives fast
04-10-2003, 12:49 AM
anybody have any suggestions?

drives fast
04-10-2003, 11:49 AM
was it something I said?

filburt1
04-10-2003, 12:42 PM
Sorry but since it involves hacking you have to ask at https://vborg.vbsupport.ru/ .

drives fast
04-10-2003, 04:01 PM
what hacking?

the php script I displayed above is already written and putting code in the phpinclude template is not hacking....it is a template modification....isn't it?

I have another page using the same script calling a different template and I was able to put code in the phpinclude to display the usernames that were on that page without hacking.....why is this different?

plus...I did ask this at vbulletin.org and I am getting the same cold shoulder

drives fast
04-17-2003, 07:37 PM
I figured it out and since I received so much kindness and friendly help...I will return the favor and post the code...
yea right

I read the post in the tips and tricks area addressing using the phpinclude template instead of hacking scripts is the only reason I even tried this modification. To receive the cold shoulder as I did wasn't very nice. This mod required zero scripts to be hacked and only code put in the phpinclude template and the varyiables added to the template of the page I wanted them to appear on.

thanks