This plugin/widget lets you add and show random quotes to your WordPress blog with ease. The plugin uses MySQL to store quotes.
You can specify an image for each quote, default image for quotes, and the option to disable images altogether.
Installation
This section describes how to install the plugin and get it working.
1. Upload directory «xmasb_quotes» to the `/wp-content/plugins/` directory
2. Activate the plugin through the ‘Plugins’ menu in WordPress
3. Add the widget to your sidebar
4. That’s it!
By default the plugin looks for an image in the folder named «images» with a name that matches the author and extension «.gif», eg. if the author is «Bart», the plugin will look for the file named «bart.gif». If an image is found it is used, else the quotes is shown without an image or default image if specified.
You can add, edit and delete quotes under Edit – XmasB Quotes.
The options for each quote:
Quote – The actual quote.
Author – The author of the quote. This is optional.
Image – The image to be used. If left blank, the name of the author will be used to search for an image. If not found, and default image is specified, the default image will be used.
Visible – Set this to «No» if you want to hide a quote without deleting it.
Set more general options under «Options – XmasB Quotes».
Options available:
Show Images – Uncheck this to disable images shown with quotes.
Default Image – If specified this image will be used if no image is found for author or specified image for quote. If left blank, quotes without images will not show an image.
Show link to author – Shows a link to xmasb.com and my plugin in the widget. Turn off if you want to.
The title for the Widget is set directly in the Widget under «Presentation – Widgets».
Title – The title to show with the Widget. Default is XmasB Quotes.
For easier management of version and statistics the plugin is hosted at WordPress.org.
This blog is using the Widget as you can see to the right.
You can also take a look at at the readme file for the plugin (XHTML formatted).

You can use the function «xmasb_print_random_quote()» to output a random quote. I’m going to include a function for printing just the actual quote as well, letting the plugin be used to insert just the actual quote anywhere.
great wp-plugin, like the idea to including images!
Thank you, autworld.
Russian language files for the plugin: http://www.wordpressplugins.ru/pics/xmasquotes-15-07-08/quotes-lang.zip
Thanks a lot, Flector. I will include this in my new next update, hopefully tomorrow.
I also plan on editing this page to update the changes. You will, of course, be credited.
hello I ‘m back, I have 2.5 wordpress and i’m using your plugin it works fine but I want to upgrade to 2.6 wordpress, what about your plugin?
is it 2.6 able? do I have to do something special?
thanks
regards,
My bad, jerry. I’ve forgot to update the tag. XmasB Quotes works with newest version of WordPress (2.6), and should work with future versions as well (unless they change something dramatically that is…).
Thanks for the reminder.
This is a great plug in
Hei XmasB, jeg får en fatal error på siste versjon av Quotes:
Fatal error: Cannot redeclare xmasb_print_random_quote() (previously declared in…
on line 117.
Var visst litt rask med å legge ut ny versjon, Iskwew. Har fikset i versjon 1.2.6. Den bør være tilgjengelig nå. Får satse på at ikke for mange rakk å få denne feilen.
Kall meg bare Lynet, XmasB
Og nå virker den, ja.
Godt å høre. Skal se om jeg ikke finner ut hvorfor den feilet imorgen. Er altfor sliten til å drive med mer «jobb» idag.
Great Plugin – alas i found two double declarations of functions, which – naturally – preventet it from working. Just deleted the incomplete and everything works fine.
Let me know if you are interested in german language files… just working on it
Alariel
Sorry about that, Alariel. I updated the files before I was finished testing. The result was non-working plugin. This is fixed in version 1.2.6.
I would be very interested in the german language files. I will send you an email with the email adress you can send them to.
Hey XmasB,
just uploaded the new version. It works so far, but – i don’t know why – the german language file seems to be somewhat messed up. There is simply no display of any string. I then tested it again with my original, and anything works fine…
I wonder what’s the difference…
I’ll get back to you when i know more
Greetings,
Alariel
Ok… so, there is no difference in the .po files, but in the .mo
Alas, the only thing i can see is, that yours is 608 bytes smaller than mine… i wonder what causes this…?
I will look into this when I get a chance, Alariel. I use POEdit as well btw.
Sorry for the late feedback – it works well
Seems that sometimes crossing fingers will help. Normaly i try to threat my computer with a sledge hammer
Greetings,
Alariel
Great, Alariel. Thanks again for the translation.
Ciao
Thanks for providing and keeping updating this nice plugin
A few questions:
- I can only make the quote but no image show up. Is it because I don’t use the widget but the code snippet pasted into a (sidebar) file? (Neither does the author show up)
- And – they should be dropped in plugins/xmasb-quotes/images – and when adding an image I should type no path?
Takkar (tenkte kanskje flere kan ha nytte av et svar på «nynorsk»)
Kjetil
PS Just testing locally for now
Hepp
Du kan stryke spørsmålene sine. Plutselig gikk det noen lys opp for meg – alt fungerer – og resultatet blir snart å se på forsiden av Dolcevita.no. Må bare file ferdig det nye designet.
Takk for innsatsen!
Kj
Godt å høre, Kjetil. Bare si ifra om det er noe.
Hello, I’m a complete noob but needed to be able to add testimonial quotes for a client’s web site and I’ve added the widget and it shows up in the sidebar but sys No quotes found. I’m adding them under Manage ? XmasB Quotes but I don’t see where they are going. There’s no place to actually see a list of the quotes, or I’m not finding where to go to look for it. Is it not saving them? Can you advise? Thank you!
The last 5 quotes are shown in the same page you add them in. There is a button in the same page for seeing a complete list. If they are not added when using the «add» button, some message should tell if there was an error.
Hi again, thanks for the reply. On the page where you adda quote, there is nothing below it. It says «Statistics» and then «No quotes found» underneath it. Likewise, when you go to the web page, it has my header, which is «Testimonials» but then it says «No quotes found» under it. I have added 5-6 quotes and they never appear on the back end in order to manage them, OR on the front end to see them.
You don’t get an error message either?
Thank you so much for writing this widget! I was just wondering if it would be possible to pass HTML (in say the quote field). Basically, what I need is line break support for each quote to go with a picture. I figured if there was a way to pass HTML I could just handle it there to better space out the quote.
Thank you for using it, Chance!
You can use HTML in the quote field. I tested it now on my testblog (with a «strong» tag) and it worked fine. Also you can add HTML before and after each element (picture, quote and author) under Settings – XmasB Quotes. In addition, there is also a xmasbquotes.css with predefined empty elements for picture, quote and author, if you really want to be in control. I believe you should be able to do what you want with these options. Good luck!
Hi
)
I’m using this great little plugin on our site’s front page (have included the code snippet in the template), but I have a funny problem:
For some reason one of the quotes just won’t show up. I’ve compared it with the other quotes that all work fine – but can’t find any differences nor explanation.
I have 8 quotes now (with image and text) – 7 showing.
Any hint?
Takk
I will look into it, Kjetil. I suspect that the sql used has a bug in it… I have seen some of the quotes on this site appear more often than any others as well.
Thanks for the HTML help. Now I am back again with a similar problem as Kjetil above. I am having some issues with the randomizer. I currently have only two quotes in use. But after many (many) refreshes only the first quote shows. If I disable the first quote then the second one shows with no problem. Once the first is re-enabled it again takes over and the second one will not be shown.
I do not have any cache-ing enabled. I added three «dummy» quotes and the second one will show with the extra quotes behind it. However, now the last «dummy» quote will not show. I am awful at coding (i will not even mention my grades) but the problem may be something as easy to fix as an off by 1 error.
Thank you again for the wonderful widget and if there is any debugging or feedback you need just let me know.
Ciao
Regarding the problem I mentioned a couple of weeks ago: Now I’ve added one-two-three more quotes – in total 8-10 quotes. The result, it seems, is that all but the last one show up. BUT the latter ones show up very rarely.
Any ideas?
(Could it have anything to do with the MySQL (4.1.11) og PHP (v4 I believe) versions used by our host?)
Kjetil
I believe it is a problem with the sql sentence used to extract the quote. The original sql was simple, but slow, so I replaced it with a more complex one. It seems that the new sql produces some strange results. On my own blog (this one) I also see that the oldest quotes are showing more often.
That was a quick one!
If I understand you correctly, it means that you will have to make a fix/update for this? Nothing I can do on my side, I believe?
Hjartans takk
Kj
(Strange language mix slipping in here and there, – but I believe you have most foreign/ non-Norwegian admirers?)
If I remember correctly the original code is just commented out, but I will release a new version soon.
(this site is mostly in Norwegian, except for this page)
Great – looking forward to it!
I installed the plugin and added the code in my sidebar, but it does not do anything ?
Are you using the code or widget?
IMPORTANT
When upgrading – remember to keep the xmasb-quotes/images folder. If not you will loose all the images associated with your quotes.
Luckily I had a backup.
Thanks
Kjetil
Hi
Just tried out your v 1.2.9 upgrade – what’s new?
(It seems like the problem with it just dispaying up to 7 quotes is still there. See comment Nov 18th)
Cheers
Kjetil
I have changed the sql for retrieving the quote. It is now supposed to use the old syntax used before I «upgraded» the sql. I will look more into this, seeing that it obviously didn’t work as expected.
If you’re overwriting the plugin when upgrading, no images should be lost. And now I realize I need to look into how automatic upgrades work…
This is a great plugin
Hi,
Is this plugins compatible with wordpress 2.7?
regards,
stef
It is compatible with 2.7, stef. I will be sure to update the info.
I have WordPress 2.6. I uploaded the plugin but the edit function only shows a title bar. Is this where I type in the quotes?
It sounds to me that you are in the Widget view. You should find the option to edit and add quotes under «Tools – XmasB Quotes». For display options, look in «Options – XmasB Quotes».
Yes, you’re right. Thanks for your prompt reply and a great plugin!
No Problem. Thanks for using my plugin, Dino Mapa.
Hello, I am new to php and trying to figure out how to add the quote to a place different than the sidebar…so I’m assuming I need a piece of code to manually place in my theme’s pages where I want it to appear. Can you let me now what that code snippet is? Thanks so much for this great plugin!
I believe you can use the php code: «xmasb_print_random_quote()». Be sure to check if the function exists like this:
i haven’t touched the code on this plugin for some months, so I hope I’m remembering correctly. I will check it up later, don’t have the code right here.