|
Forum Integration - Recent Posts on Main Site
|
|
02-15-2010, 08:16 AM
Post: #11
|
|||
|
|||
|
RE: Forum Integration - Recent Posts on Main Site
<?php
chdir("./board/"); // path to MyBB define("IN_MYBB", 1); require("./global.php"); ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>FP SharePoints : A Starvoice community Initiative</title> <META http-equiv=Content-Type content="text/html; charset=utf-8"><LINK href="style.css" type=text/css rel=stylesheet> <style type="text/css"> <!-- body,td,th { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 10px; } body { margin-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; background-color: #F8FCFC; background-image: url(bg.jpg); } .style1 { color: #FFFFFF; font-size: 14px; font-weight: bold; } .style3 {color: #FFFFFF; font-size: 10px; font-weight: bold; } .style8 { font-size: 8.5pt; font-family: Verdana, Arial, Helvetica, sans-serif; color: #000000; font-weight: bold; } a:link { color: #183C4A; text-decoration: none; } a:visited { text-decoration: none; color: #183C4A; } a:hover { text-decoration: underline; color: #0099CC; } a:active { text-decoration: none; color: #0099CC; } .style10 {color: #FFFFFF} .style11 { color: #000000; font-weight: bold; } .style12 { font-size: 12 } --> </style> <script type="text/javascript"> <!-- function MM_jumpMenuGo(objId,targ,restore){ //v9.0 var selObj = null; with (document) { if (getElementById) selObj = getElementById(objId); if (selObj) eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'"); if (restore) selObj.selectedIndex=0; } } //--> </script> <table width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> <td width="24%" height="50" background="h1.jpg"><img src="headerlogo.jpg" alt="" width="300" height="50" /></td> <td width="43%" background="h1.jpg"> </td> <td width="15%" background="h1.jpg"><img src="TOPSTRIP.jpg" width="181" height="50" border="0" usemap="#Map2" /></td> <td width="18%" background="h1.jpg"> </td> </tr> </table> <br /> <br /> <table width="968" border="0" align="center" cellpadding="0" cellspacing="0"> <tr> <td width="360" height="30" valign="middle" class="style8"> </td> <td width="520" rowspan="5"> </td> <td width="88" rowspan="5" valign="top"> </td> </tr> <tr> <td height="150" valign="top" bgcolor="#FFFFFF"><?php $query = mysql_query(" SELECT t.*, u.username FROM mybb_threads t LEFT JOIN mybb_users u ON (u.uid=t.uid) WHERE 1=1 AND t.visible='1' AND t.closed NOT LIKE 'moved|%' ORDER BY t.lastpost DESC LIMIT 0, 6" // Change the last digit to how many recent post you want to be shown ); $list = ''; while($fetch = mysql_fetch_array($query)) { $list .= "<strong><a href=\"forums/showthread.php?tid={$fetch['tid']}\">".htmlspecialchars_uni($fetch['subject'])."</a></strong><br />"; $poster = "<a href=\"forums/member.php?action=profile&uid=".$fetch['uid']."\">{$fetch['username']}</a>"; $list .= "Created by: {$poster}<br />"; $list .= "<i>" .$fetch['replies']. " Replies</i>"; $list .= "<i> , " .$fetch['views']. " Views</i><br />"; $list .= " (<i>Last post by: " .$fetch['lastposter']. "</i>)<br /><hr width=\"50\"><br />"; } //output echo $list; ?></td> </tr> <tr> <td height="30" valign="middle"> </td> </tr> <tr> <td height="25" valign="top" bgcolor="#FFFFFF"> </td> </tr> <tr> <td height="27" valign="top" bgcolor="#FFFFFF"> </td> </tr> </table> <p><br /> </p> <table width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> <td width="50%" height="50" align="center" valign="middle" background="h1.jpg"><span class="style3">All copy right reserved by Four Points by Shearton</span> <span class="style3">| Share Point A starvoice Community Initiative |</span></td> <td width="50%" background="h1.jpg"> </td> </tr> </table> <map name="Map2" id="Map2"><area shape="rect" coords="12,21,79,31" href="home.php" alt="Home Page" /> <area shape="rect" coords="111,18,162,33" href="http://www.fpsharepoints.com/board/memberlist.php" alt="Associates Details" /> </map></body> </html> |
|||
|
02-15-2010, 08:46 AM
Post: #12
|
|||
|
|||
|
RE: Forum Integration - Recent Posts on Main Site
I'm not at my home computer but I don't think you need the ./
<?php chdir("board/"); // path to MyBB define("IN_MYBB", 1); require("./global.php"); ?> |
|||
|
03-09-2010, 08:11 AM
Post: #13
|
|||
|
|||
RE: Forum Integration - Recent Posts on Main Site
(02-15-2010 08:46 AM)punked Wrote: I'm not at my home computer but I don't think you need the ./ & my question is that if i want recent post from only for section " like i have Forum and there is category " Downtown Property" i want to show only downtown Property Recent post is it possible? not all indivisual posts only from one speifice category Kind Regards, Muneeb |
|||
|
03-15-2010, 03:00 PM
Post: #14
|
|||
|
|||
|
RE: Forum Integration - Recent Posts on Main Site
& my question is that if i want recent post from only for section " like i have Forum and there is category " Downtown Property" i want to show only downtown Property Recent post is it possible? not all indivisual posts only from one speifice category
Kind Regards, Muneeb |
|||
|
03-17-2010, 07:57 PM
Post: #15
|
|||
|
|||
|
RE: Forum Integration - Recent Posts on Main Site
Thanks man.
|
|||
|
03-21-2010, 05:40 PM
Post: #16
|
|||
|
|||
|
RE: Forum Integration - Recent Posts on Main Site
my index is http://www.tech2game.com and forum is http://www.forum.tech2game.com can you tell the both codes for my forum properly?
![]() |
|||
|
03-21-2010, 06:59 PM
Post: #17
|
|||
|
|||
|
RE: Forum Integration - Recent Posts on Main Site
How could I do this for news posts? Maybe even who's online?
|
|||
|
03-22-2010, 01:05 AM
Post: #18
|
|||
|
|||
RE: Forum Integration - Recent Posts on Main Site
(03-21-2010 05:40 PM)tech2game Wrote: my index is http://www.tech2game.com and forum is http://www.forum.tech2game.com can you tell the both codes for my forum properly? hm ? didn't you pay someone to get it coded ? ![]()
|
|||
|
03-27-2010, 05:36 PM
Post: #19
|
|||
|
|||
|
RE: Forum Integration - Recent Posts on Main Site
hi.
can we the use of this for weblog? |
|||
|
03-27-2010, 09:24 PM
Post: #20
|
|||
|
|||
|
RE: Forum Integration - Recent Posts on Main Site
I'd love to use this, as the snippet I'm currently using isn't as refined.
... but I'm getting the following error Quote:WARNING: mysql_fetch_array(): supplied argument is not a valid MySQL result resource My host says I have currently MySQL version 5.0.89-community and PHP version 5.2.12. Bring your dreams of sky and wings; come to share the memories of our lives. |
|||
|
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)
Search
Member List
Calendar
Help





![[Image: PHgwI.png]](http://i.imgur.com/PHgwI.png)
![[Image: 350x19.jpg]](http://mania-creative.com/src/banner/350x19.jpg)
![[Image: tstargermany.png]](http://www.mybbwebhost.com/u/tstargermany.png)