|
Forum Integration - Recent Posts on Main Site
|
|
01-07-2010, 11:20 PM
Post: #1
|
|||
|
|||
|
Forum Integration - Recent Posts on Main Site
I'm not too savvy at php but using some resources from here and a bit of time I've got a great working version to integrate your main site with recent forum posts.
Although fully editable, this script will display: Subject Subject Creator Replies Views Last Poster a working example can be found here: http://www.backofthelandingnet.co.uk Instructions: 1. Put this php script at the beginning of the page you want to display the recent posts on line 1 (before the HEAD tags) Code: <?php2. edit the chdir to the path to your forum 3. Insert the code below where you want recent posts to be displayed Code: <?php4. Change the amount of recent posts you want to have displayed That's it! |
|||
|
01-07-2010, 11:30 PM
Post: #2
|
|||
|
|||
|
RE: Forum Integration - Recent Posts on Main Site
Looks Good. Let me have a try with this.
Thanks. vBulletin/Wordpress/Magento/MyBB Developer and Designer |
|||
|
01-08-2010, 02:00 PM
Post: #3
|
|||
|
|||
|
RE: Forum Integration - Recent Posts on Main Site
Awesome! Thanks a lot
|
|||
|
02-05-2010, 07:28 PM
(This post was last modified: 02-06-2010 04:36 PM by themulhaq.)
Post: #4
|
|||
|
|||
|
RE: Forum Integration - Recent Posts on Main Site
Im getting this error ... I dont know why
Warning: chdir() [function.chdir]: No such file or directory (errno 2) in /home/fpshar5/public_html/home.php on line 2 Warning: require(http://www.fpsharepoints.com/board/global.php) [function.require]: failed to open stream: No such file or directory in /home/fpshar5/public_html/home.php on line 4 Warning: require(http://www.fpsharepoints.com/board/global.php) [function.require]: failed to open stream: No such file or directory in /home/fpshar5/public_html/home.php on line 4 Fatal error: require() [function.require]: Failed opening required 'www.fpsharepoints.com/board/global.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/fpshar5/public_html/home.php on line 4 anyone will answer of my above question? |
|||
|
02-08-2010, 06:55 AM
Post: #5
|
|||
|
|||
|
RE: Forum Integration - Recent Posts on Main Site
My website have html pages, is there any way to add that code in those html ed pages ?
|
|||
|
02-08-2010, 09:19 AM
Post: #6
|
|||
|
|||
|
RE: Forum Integration - Recent Posts on Main Site
Change them to PHP pages (Just changing the extension is enough), then put that code in where wanted.
|
|||
|
02-08-2010, 11:11 PM
Post: #7
|
|||
|
|||
RE: Forum Integration - Recent Posts on Main Site
(02-05-2010 07:28 PM)themulhaq Wrote: Im getting this error ... I dont know why Can you post the exact code you have used and also a link to your forums? |
|||
|
02-10-2010, 09:39 AM
(This post was last modified: 02-10-2010 09:39 AM by Cameron:D.)
Post: #8
|
|||
|
|||
|
RE: Forum Integration - Recent Posts on Main Site
When using the include function, you reference the file on the server, not the URL, so it would be
Code: <?php |
|||
|
02-10-2010, 11:27 AM
Post: #9
|
|||
|
|||
|
RE: Forum Integration - Recent Posts on Main Site
Thanx this i was searching from many time. Good work.
You Too Can Earn Like Me
|
|||
|
02-10-2010, 10:48 PM
(This post was last modified: 02-10-2010 10:53 PM by TStarGermany.)
Post: #10
|
|||
|
|||
|
RE: Forum Integration - Recent Posts on Main Site
if you have the mybb global.php integrated already,there's no need to form complicated sql commands for getting proper results
usually, a query like this is sufficient: PHP Code: $query = $db->simple_select('threads', '*', "fid='{$fid}' ORDER BY tid DESC --no ad, just info-- if you want, you can look at my news page (click), the script which catches+formats+outputs the news is just 4kb large (90% of it html/css formatting of the post content). it's even more lightweight than Tikitiki's site news plugin). ![]()
|
|||
|
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)
Search
Member List
Calendar
Help





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