MyBB Community Forums

Full Version: Displaying News on your homepage
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33
i fixed the problem
i founded a nice mod called news plugin (search mybb mods)

only problem whit it is that you need to edit a little to make it fit to your homepage (it shows on the news.php page and not on your homepage)
so you just make it shows from that page into your website and you get like my website

http://powerchaos.info

Thank you
Greets From The Crasher
Change:
""fid='{$fid}'"
To:
"*"

It should just grab the latest posts from all forums then.
$query = $db->simple_select('threads', '*', "* ORDER BY tid DESC LIMIT {$limit}");
i have modify but the script give me a error.
MyBB has experienced an internal SQL error and cannot continue.

SQL Error:
1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '* ORDER BY tid DESC LIMIT 5' at line 1
Query:
SELECT * FROM mybb_threads WHERE * ORDER BY tid DESC LIMIT 5
Oops, my bad. I read the query wrong.

Yeah, that should just be:
$query = $db->simple_select('threads', '*', "ORDER BY tid DESC LIMIT {$limit}");
MyBB has experienced an internal SQL error and cannot continue.

SQL Error:
1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'ORDER BY tid DESC LIMIT 5' at line 1
Query:
SELECT * FROM mybb_threads WHERE ORDER BY tid DESC LIMIT 5


XD
ugual error
Is it possible to implement a pagination function along with this? so say like it goes to a specified number of news posts, then cuts off and carries on another page, like.

./news.php?page=2
(2008-11-28, 03:51 PM)Craigw Wrote: [ -> ]Is it possible to implement a pagination function along with this? so say like it goes to a specified number of news posts, then cuts off and carries on another page, like.

./news.php?page=2
It already does hence the news per page setting. Lets say you limit it to 5, it will show 5, than at the bottom of the site news it will paginate.
(2008-12-02, 04:48 PM)bctrainers Wrote: [ -> ]
(2008-11-28, 03:51 PM)Craigw Wrote: [ -> ]Is it possible to implement a pagination function along with this? so say like it goes to a specified number of news posts, then cuts off and carries on another page, like.

./news.php?page=2
It already does hence the news per page setting. Lets say you limit it to 5, it will show 5, than at the bottom of the site news it will paginate.

oh thanks didnt know Toungue, found + implemented ^_^

you get a heart shaped cookie Heart
sorry for double post, but how would i get the [IMG] mycode to work?, seems like it doesnt display.

Example: http://resievil.com/news.php
Bump for [IMG] MyCode problem.
Has anyone found the cause of the [IMG] tag not parsing on the news page.

nvm finally found it Smile, just add this line on the array options

'allow_imgcode' => '1'
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33