ACMODATION.COM
welcome to my space
X
Welcome to:acmodation.com
 HOME   Basic HTML: Manipulating Images
Basic HTML: Manipulating Images
Published by: webmaster 2008-07-03
Wrox::Visual Basic Graphics Programming:Book Information and Code ::
Manipulating Bitmaps 29. Saving Image Files 32. Section 4 Wrap-Up 33. Section 5: Using Transformations 33. Basic Transformations 33
http://www.wrox.com/WileyCDA/WroxTitle/productCd-0470343486.html
HOME
Lesson: Working with Images (The Java™ Tutorials > 2D Graphics)::
Directly creating a Java 2D image and rendering to it. The basic operations with images are represented in the following sections:
http://java.sun.com/docs/books/tutorial/2d/images/index.html
HOME
Basic HTML: Manipulating Images - Official Becker Family Web Site::
Basic HTML: Manipulating Images Web Design and Web Scripts.
http://beckerfamily1.com/forum/showthread.php?t=500
HOME
(with updates by editorial staff)

Use these to jump around or read it all
Placement On Page
Aligning Text With Images
Changing Image Size
The <HR> Command

Virginia Tech's Luna Insight Digital Image Database::
The software allows you to search image collections, manipulate selected manipulating images; creating presentations and exporting them in HTML or
http://www.lib.vt.edu/services/branches/artarch/services_insight.html
HOME

Just as I thought a primer, Primer #3, was required explaining how to manipulate text, I also think one is needed on how to manipulate images. Believe it or not, manipulating images is much the same as manipulating text. So, here we go.


Basic HTML Tag Tutorial::
So, if you want to use a large image you will have little left for other items on the . For more advanced information of manipulating the appearence of a
http://www.austen.com/tutorial/
HOME
Manipulating Images in html::
Manipulating Images in html, PDF, Print, E-mail. Tag it:. Delicious. Furl it! How to write very basic HTML (0) (0). Category: HTML. Grab a subscription!
http://www.webdotdev.com/nvd/content/view/796/
HOME
Placement On The Page

First lets worry about placing the image somewhere on the page. The default is justified to the left. If you write an image tag on a page, the image will pop up hard left.

If you want to have an image placed in the center of the page, you use the CSS, text-align: center; as described in Primer #3.

But how do we get the image to the right of the page? Well, how did we get text to the right? By adding the text-align: right;, right? Could it be we do the same thing here? Why yes, it could.

Heres the format:

<div style=text-align: center;><IMG src=image.gif ALT=image></div>

Heres what you get using sally.gif in place of image.gif:



Aligning Text With Images

Images dont always stand alone. You will often want text alongside them. Here you will float the image, and then allow the text to wrap around it. Clever stuff!

Here are the formats:

<div style=float: left;><IMG src=sally.gif> text text text</div>

<div style=float: right;><IMG src=sally.gif> text text text</div>

And heres what it all looks like:


This is text wrapping around an image floated to the left. We will fill in lots of text here just to make the point...


This is text wrapping around an image floated to the right. Its worth telling you now that you cant float an image to the center. Odd really, but then, floating to the center usually involves a two column layout,

You may notice Ive used an extra CSS property, clear:left; on the second one.
<div style=float: right; clear: left;><IMG src=/images/sally.gif></div>
This is to ensure that the next float is clear of the one above it. You can use left, right or both as values.


Changing Image Size

To begin this discussion, let me state that images on a computer are not like photographs. Computer images are made up of a lot of little colored dots. Theyre known as picture elements or pixels for short. So, just remember that during this part of the Primer, numbers refer to pixels rather than inches, or centimeters, or whatever. When I say pixels, Im talking little colored dots.

Every image is made up of pixels. The more pixels per inch the image has the better, and more detailed, the image will appear. Of course, that also means the image will take up a whole lot more bytes on your hard drive. Youre going to find that most images on the Web are 72 and 100 pixels per inch. Yes, there are other settings, but 72-100 is a good trade-off between loss of detail and bytes required.

Okay, so every image is made of pixels. This means that you can also denote an image by number of pixels. For example, the sally.gif image is 97 pixels high by 64 pixels wide. How do I know that? I have an expensive graphics program that tells me so. How would you know? Without a specific program, you wouldnt. Youll have to play around with the numbers in these commands a little bit, but its easy to do.

You might also want to open the image by itself in the Netscape Navigator browser window. Do that by choosing OPEN FILE under the FILE menu. When the picture pops up, look at the title bar along the very top. The height and width should be there.

Of course, you can also go out onto the Web and surf around for a shareware graphics program. My personal favorite is PaintShop Pro. You get it for free for 30 days and then its like $80 or so to get it for good. There are even a few open source alternatives out there.

Heres what you do. Denote to the image command how many pixels high by how many pixels wide you want. The sally.gif image is 64X97 pixels. If I want the image to appear smaller, I will ask for the pixels to be smaller, say 30X55. If I want it bigger, I would set the pixels larger, say 100X250. Just remember form. If you make the image smaller or larger, you must keep the same general square, rectangle, or whatever, form.

Of course, if I want to, I can totally distort the picture.

Heres the coding:

<IMG HEIGHT=## WIDTH=## src=image.gif>

Notice the HEIGHT and WIDTH attributes nestled right where the ALIGN command went before. You will replace the ## with a number of pixels for height and width. Here are the three examples:

This is normal size:

This is 30X55:

This is 100X250:

This is 100X23:

However, if the image is bigger than you need you are better off making it smaller in a graphics package, simply because it will be a smaller file size, so your page will load faster.

Making it bigger isnt really a great idea either, because it will tend to go pixelly, if I can call it that!

Putting the actual dimensions of the image in is a good idea, because the page will load with the correct amount of space allocated to the images - otherwise the image will download and the page will move down and rearrange for every image that downloads.


The <HR> tag

The WIDTH command also works on the <HR> command, except youll use percentages. Watch this:

<HR WIDTH=40%> gives you this:


<HR WIDTH=64%> gives you this:


You get the idea, yes?

That wraps it up. Try these in the comfort of your own home under the supervision of an adult. If you are an adult, then find a kid who can program the VCR to help you along.

Placement On Page
Aligning Text With Images
Changing Image Size
The <HR> Command



Pre-Article:Basic HTML: Images
Next-Article:Basic HTML: Graduation
  • Goodies To Go! Newsletter #350
  • Geeks for Rent: Changing IT Support for SMBs
  • New Debian Project Leader Takes Charge
  • DNS-Based Phishing Attacks on The Rise
  • June 24, 2002-- Newsletter #186
  •  
  • Mobile VoIP: Whats In a Name?
  • February 11, 2001-- Newsletter #167
  • CodeGuru Update eNewsletter - March 22nd, 2005
  • Tutorial: Installing Apache and PHP Under Win32
  • New AMD chipsets
  • #If you have any other info about this subject , Please add it free.#
    Your name:
    E-mail:
    Telphone:

    Your comments:


    If you have any other info aboutBasic HTML: Manipulating Images, Please add it free.
     Homepage | Add to favorites | Contact us | Exchange links | LOGIN | Site map | 
    Copyright© 2008 acmodation.com        Site made:CFZ