REGISTER or LOGIN to have the annoying ads removed.
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Random Quote Generator

I am looking for a plugin that displays a random quote or joke whenever the page is reloaded, ideally the display box would be at the top of the index.

Is any one aware of such a plugin, or can I request one to be made?

Many Thanks
Lol, what?!
PHP Code:
$query $db->simple_select("quotes""*""", array("order_by" => "RAND()""limit" => 1));
$quote $db->fetch_array($query);
$randomquote htmlspecialchars_uni($quote['quote']); //labrocca edit 

That's the query you could use. Table called mybb_quotes, quote is (unsurprisingly) the name of the column with the quote in. Hook into index_start, put {$randomquote} in the template.

Give me a day or two and I might make it as a normal plugin file.
If you are looking for a random image generator i could help you out.
[Image: jsnippetsbanner.jpg]
Latest Theme: CMS BB.
Make just one change.

$randomquote = htmlspecialchars_uni($quote['quote']);
Ah yes, updated post.

Possibly Related Threads...
Thread Author Replies Views Last Post
  Random Quote Generator mortalc 2 1,562 May 06, 2010, 05:29 AM
Last Post: LS 134
  Quote Find. iR00T 2 1,696 Jan 19, 2010, 01:35 PM
Last Post: Jessie S.
  Generator Xeon 0 957 Oct 23, 2009, 08:38 PM
Last Post: Xeon
  Sitemap Generator RPG 2 2,242 Feb 27, 2009, 06:48 PM
Last Post: labrocca
  Select quote on MyBB S!ck 16 9,113 Dec 17, 2008, 01:28 PM
Last Post: S!ck

Forum Jump:

Users browsing this thread: 1 Guest(s)