Free Republic
Browse · Search
News/Activism
Topics · Post Article

To: Utilizer
Images:
<img src="http://upload.wikimedia.org/wikipedia/en/a/a3/Bobdobbs.png"><p>
<img src="http://upload.wikimedia.org/wikipedia/en/a/a3/Bobdobbs.png" width="30%">
<img src="http://upload.wikimedia.org/wikipedia/en/a/a3/Bobdobbs.png" width="15%">
<img src="http://upload.wikimedia.org/wikipedia/en/a/a3/Bobdobbs.png" width="7%">
<img src="http://upload.wikimedia.org/wikipedia/en/a/a3/Bobdobbs.png" width="4%">
<img src="http://upload.wikimedia.org/wikipedia/en/a/a3/Bobdobbs.png" width="2%">
<img src="http://upload.wikimedia.org/wikipedia/en/a/a3/Bobdobbs.png" width="1%"> .
Yields:

.

J. R. "Bob" Dobbs receding into infinity...

<img src="http://mumble.com/image.jpg"> substitute the actual source of the image for http://mumble.com/image.jpg This image must be out on a server on the web someplace, not on your machine. This is why people have flickr and picassa accounts. You can easily find out the URL of an existing picture on the web by right-mousing over it and selecting Open Image In New Tab. This will open a tab on your browser containing only that image. The URL of that tab is the one to use as your src="" value.

Some of the photo storage sites on the web (flickr) try to drive web traffic to their site to harvest advertising by providing a convenient pointer to their site that isn't a URL to a .jpg To get the proper URL try right mousing over the image and select Open Image in New Tab. This should get you the naked image itself, without all of the surrounding advertising. This is the URL you want to use.

Access Denied! - No Hotlinking - Occasionally you will see an image that looks good on the site of origin but won't show up if you use it in a posting. Many sites block what they term as "hot-linking" thinking that people who link to their images from pages that are not theirs are stealing their hard paid for bandwidth. They have a point. Either use another image or host it on your own site to fix this problem.

Often the poster will see the image that hot-linking is not allowed for while other users are whining about no image present and red X's. This is because the poster's browser has cached the image and doesn't have to go to the blocked site to get it. A refresh of the page should show what is what.

Size: You can easily vary the size of a given image by specifying it. You may specify size in terms of pixels, em (one character height-width), or percent of enclosing container. Given the wide variation in display platforms the best results are usually obtained by using percent to specify size.

<img src="http://upload.wikimedia.org/wikipedia/en/a/a3/Bobdobbs.png" width="15%"> Yields:

If you are specifying the size of an image it is best to do it in only one dimension and let the computer figure out what the other dimension should be. This will result in images that have not been distorted. Another neat trick is to specify the image size as a percentage of the width of the container the image sits in. This results in a uniform presentation of the image across all possible platforms without having to compute the image size at all.

The native size of the J. R. "Bob" Dobbs picture above is 324x216 pixels. Typical screen pixels per inch numbers for normal displays are in the range of 75 to 150 so the original Dobbs'Head will likely appear on your screen somewhere between 2.88 to 1.44 inches wide.

The next row of Dobbs'Heads are scaled to the width of the enclosing container. We use the width because its value is mostly apparent on the screen. The value of the container's height is less so. The first Dobbs'Head is scaled to 30% of the width of the container. The next at about half that, and so forth... This produces a line of attractive Dobbs'Heads receding into infinity that occupies about half the width of your page, all without needing to know how wide your page is. The size of the images will change if you grab the edge of the page and make it wider or thinner. This is the reason you want to scale images (and anything else, really) by percentages rather than pixels.

In the past it was best to keep your scaling to powers of 2 to minimize scaling artifacts. Current smoothing algorithms and processor speeds make that pretty much unnecessary. Remember that scaling up will not introduce new detail into the existing picture.

Stationary images usually end with .jpg or some variation. Moving images are possible using images which end in .gif The .gif format allows for short sequences of stationary images to be presented like a very tiny movie. Another common format is .png which is a static image format from Microsoft. You will also see images that are .pdf Postscript Document Format. Images in .pdf format will often not post on websites because the .pdf file can easily be a virus container.

You can position an image relative to its surrounding elements by adding the attribute align="middle" to the tag. Recognized attribute values are top, bottom, middle, left and right.

<p><img src="http://enemiesforeignanddomestic.com//sj/images/61cb2_zQLMZ.gif" align="right" alt="Kittie doing its nails."></p> Yields:

This is some text to show how it flows around the image. This is before the image in the source HTML with a paragraph called out before the text. Isn't the expression of the cat's face just priceless? ♣

Kittie doing its nails.

And this is text right after the image. I have found left and right attributes to be useful, the rest not so much. You really seem to have to have quite a bit of text for the behavior of the flow to come out. Dinking with the browser width seems to help illuminate the behavior of the flow. Perhaps a smaller picture in the x-axis? But it's sooo cute.

Does adding a paragraph move the text down below the image? Nope, sure doesn't. Think of the anchor as the upper left corner of the image and as far as HTML is concerned that corner goes right after the club following "priceless", but it is aligned right so it starts on the line with the club ♣ and hangs to the right.

In general, if you are posting images it is beneficial to place the image in a paragraph of its own and use a closing tag with <p> </p> as it helps the browser software properly place images.

The alt="Kittie doing its nails." specifies the text that appears when you mouse over the image. Some folks use these descriptors by running them through vocal-synthesis software. The blind using computers find these descriptors quite helpful. It's important to remember that an image (as well as any other element) can be used as the clickable part of a hot-link.

Freedom ≠ Free Stuff☭
I, for one, welcome our new Cybernetic Overlords /.
Mash Dobbshead® for HTML, bop Hello_Cthlhu for XAMPP

19 posted on 12/16/2015 3:37:17 PM PST by Mycroft Holmes (The fool is always greater than the proof.)
[ Post Reply | Private Reply | To 17 | View Replies ]


To: Mycroft Holmes

Many, many thanks for all the help. This page is now saved for future reference and so I can practice offline as well.

Thanks again!


20 posted on 12/16/2015 3:43:42 PM PST by Utilizer (Bacon A'kbar! - In world today are only peaceful people, and the muzlims trying to kill them)
[ Post Reply | Private Reply | To 19 | View Replies ]

Free Republic
Browse · Search
News/Activism
Topics · Post Article


FreeRepublic, LLC, PO BOX 9771, FRESNO, CA 93794
FreeRepublic.com is powered by software copyright 2000-2008 John Robinson