A few folks commented to me about how nice it would be to have a random FSTDT appear on in their signature on messageboards, or have a random quote on their blog. So, I went ahead and wrote a script to do that.
Example:The styles are highly customizable, use this form to generate your own style (all fields are optional, all colors are written in hexadecimal):
There is a problem with setting the image too narrow:
If you set the image too narrow (such as 10px wide), the text will format incorrectly and it
won't look good. For the text to display without error, it the image size must be larger
than the width of the single most longest word in the quote. Usually, anything width greater
than 250px will display just fine.
Customized quotes work great on vBulletin, but not on phpBB
Unfortunately, phpBB has a convoluted BBCode engine, and on most boards phpBB will not format
its [img]image_URL[/img] tags if image_URL does not
end with .gif, .jpg, .png, or .bmp. My script ends with .asp and requires a few arguments to
format properly. However, there is a known workaround: add &filetype=.gif to the image URL, and it should work correctly.
Don't set your background and font color to the same thing:
This is a no-brainer.
Don't use "#"'s in your hexadecimal code:
Most of us are familiar with writing color=#FF00FF or
background : #00F0AB;, however if you try to use that format with the script for
any color values, the image won't acknowledge your hex values. This is due to the fact that
most browsers interpret the "#" symbol as anchor, and not as part of a querystring, so
the browser will ignore all text after the "#" causing you to loose all of your formatting.
When using Hex, just exclude the "#" before your value, like this: #FF00FF
-> FF00FF.
Transparency is set by default:
If you want a colored background, you have to disable transparency.
All borders thicker than 1px are solid:
A software limitation prevents non-solid borders thicker than 1px from displaying properly,
and unfortunately there is no workaround. Hopefully this won't be a problem.
Text cannot be anti-aliased:
Anti-aliasing causes "fringies", making for an unclean GIF. It also takes more processing
power to anti-alias text than otherwise, which increases the lag time in GIF output. So,
due to these limitations, I can't enable anti-aliasing without hurting the quality of the
script.
Quotes aren't actually "random":
You won't get a truly random quote from the FSTDT database, because calling from the database
everytime an image is displayed is server intensive. Instead, a small file of about 10 random
quotes is used to generate the text; the file is refreshed with 10 new quotes everyday. So,
at the most, if you use my script then you can only display up to 10 distinct quotes in any
given day.
The script uses up my bandwidth:
The script I've written is hosted on the FSTDT.com servers, and everytime its executed it uses
FSTDT.com resources. So far, I haven't had a problem with bandwidth, however if the script
becomes to cause problems for my site, then I'll have to remove it. I don't suspect I will
have to do anything like, so don't worry about it :)
If their is an error with the script, contact me:
If the script formats text incorrectly, or displays a red "X", contact me at
fstdt@hotmail.com or on the
FSTDT Forums and let me know.