When I download a gif from my website script, it appears like a thin line. I expected to see the 1" by 1" graphic solid color image that appeared on the site. Is it just a thin line that expands once the web page size is set? How does this work?

9 Years
Discussion Span
Last Post by DistantGalaxy

when an image is used as a background, it can be,
repeat-x repeat-y or repeat-both
to tile the image in the direction of its repeat
a tiny image afew bytes in size,
two squares, become a checkerboard
a few leaves repeats to a forest
instead of a very large graphic to be downloaded
then the image looks 'right' at most resolutions and window sizes


You can edit the background image with a repeated x and repeated y by editing the codes of the background.


what's wrong with the answer?

You've revived a thread that has been dead for five years. You might want to familiarize yourself with Daniweb's rules.

Apart from that your example contains errors. The image height attribute has become part of the querystring because of some missing characters. And the IMG tag isn't closed properly.

In fact it won't validate as HTML. IMG tags should have an alt attribute these days, and a minimal HTML file needs a HEAD and TITLE tag.

That said, it's usually best to keep code examples as short as possible. You could have discarded the HTML and BODY tags altogether, and the lengthy querystring is unnecessary.

Don't use any old domain name in your URLs. Prefer example.com or one of the other TLD domain names set aside for this purpose. Linking to real domains can have unexpected effects, and you can't guarantee what that link might point to in say five years time.

Edited by DistantGalaxy

Votes + Comments
Well said
This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.