The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Feed latest topics onto a non vb page
|
#2
|
|||
|
|||
Code:
$result = mysql_query("SELECT * FROM teensay_vbboardscurrent.thread WHERE forumid!=59 AND forumid!=62 ORDER BY 'threadid' DES$ $count = 0; while ($row = mysql_fetch_array($result)) { $count++; ( (is_float($count/2)) ? $color = '#E8F2FF' : $color='#C1DCFF' ); $tpl->assign('ht_bg', $color); $tpl->assign('ht_id', $row['threadid']); $tpl->assign('ht_title', $row['title']); $tpl->assign('ht_name', $row['lastposter']); $tpl->assign('ht_date', date("d.m.y h:i:s",$row['lastpost'])); $hottopics .= $tpl->parse($templatepath.'/home/hottopics_template.html'); } $ch .= '</table>'; |
#3
|
|||
|
|||
m.. lookin for more help as i wudnt no where to put thid
|
#4
|
||||
|
||||
Quote:
|
#5
|
|||
|
|||
Quote:
Code:
$result = mysql_query("SELECT * FROM yourdbname.thread WHERE forumid!=59 AND forumid!=62 ORDER BY 'threadid' DES$ yourdbname needs to be your forums database name The forum ID numbers are just forumid's that you dont want to display in the latest posts eg. staffroom, debug, etc You'll also need to include a config.php file or something with your db details in it Also thats just the code needed. you'll need to stick it in the design yourself |
#6
|
|||
|
|||
im to lost to doit sorry but im a newbie so i need it to be like a hack with instructions lol
|
#7
|
|||
|
|||
It really depends on what specifically your looking to pull and how you want the information pulled. The above doesn't make use of vBulletin's coding directly or allow you open modification from the template system (which would ease how you display the data).
Insert the following into your PHP file. PHP Code:
Code:
$thread[title] <br /> Posted By: $thread[postusername] <br /> Posted On: $dateposted <br /> <br /> The above MySQL Query will pull the last 5 threads from the database and use the 'latest_thread_display' template as the acting template to display the data. To use the above, however, you will need to include global.php within your PHP file, as noted below, else the functions will not...function . PHP Code:
|
#8
|
|||
|
|||
this is what my file looks like and get error on
http://www.globalvibez.com/test.php PHP Code:
|
#9
|
|||
|
|||
Ok, here's what you need to do :-).
Create a PHP file called testing.php and insert the following inside (verbatim) PHP Code:
Code:
$threaddisplay Now create a new template called 'custom_latest_thread_display' (again, without the quotes) and insert the following into it. PHP Code:
You need to change the path to global.php to your corresponding path. If you are on a CPanel based server (i.e. you can login to your control panel via domain.com/cpanel), then you need to use /home/cpanelusername/public_html/forum/global.php. Let me know if this works for you. If not, I will create a file for you myself and help you as much as I can given my free time . |
#10
|
|||
|
|||
Put javascript on the html page and pull your latest threads from your external.php.
Latest vBulletin Threads on HTML Pages with Javascript. The file is a freebie. Use it as is or feel free to borrow from it. |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|