Picture sizing for target frames

P

Pascal Herczog

I have a page containing 2 frames, the top has a table of hyperlinks, which,
if you click on them, each show a different picture in the bottom frame
(i.e. target base is set to "bottom").

e.g., in the top frame, a table data entry would be:
<td width="25%"><a
href="../My%20Jokes/Pictures/airplane.jpg">Airplane</a></td>

What I would like to do is constrain the size (width, height) of the actual
picture shown in the bottom frame when the user clicks on the text
"Airplane". I have seen plenty of examples setting width etc when the
hyperlink itself is a picture, but I can't see how to set the width/height
attributes in this case. Hence I end up with a picture that doesn't fit into
the bottom frame, which spoils the effect. As I've got loads of pictures, I
don't really want to have to resize them all manually first.

Can anyone help?
Pascal.
 
N

Neredbojias

With neither quill nor qualm, Pascal Herczog quothed:
I have a page containing 2 frames, the top has a table of hyperlinks, which,
if you click on them, each show a different picture in the bottom frame
(i.e. target base is set to "bottom").

e.g., in the top frame, a table data entry would be:
<td width="25%"><a
href="../My%20Jokes/Pictures/airplane.jpg">Airplane</a></td>

What I would like to do is constrain the size (width, height) of the actual
picture shown in the bottom frame when the user clicks on the text
"Airplane". I have seen plenty of examples setting width etc when the
hyperlink itself is a picture, but I can't see how to set the width/height
attributes in this case. Hence I end up with a picture that doesn't fit into
the bottom frame, which spoils the effect. As I've got loads of pictures, I
don't really want to have to resize them all manually first.

Can anyone help?
Pascal.

Load the image into a page (-via js or php, etc.,) which is loaded into
the bottom frame.
 
J

Jonathan N. Little

Pascal said:
I have a page containing 2 frames, the top has a table of hyperlinks, which,
if you click on them, each show a different picture in the bottom frame
(i.e. target base is set to "bottom").

e.g., in the top frame, a table data entry would be:
<td width="25%"><a
href="../My%20Jokes/Pictures/airplane.jpg">Airplane</a></td>

What I would like to do is constrain the size (width, height) of the actual
picture shown in the bottom frame when the user clicks on the text
"Airplane". I have seen plenty of examples setting width etc when the
hyperlink itself is a picture, but I can't see how to set the width/height
attributes in this case. Hence I end up with a picture that doesn't fit into
the bottom frame, which spoils the effect. As I've got loads of pictures, I
don't really want to have to resize them all manually first.

Well actually your should! Images at resolutions meant for printing
(thousands of pixels on a side) are not really suitable for use on the
web where 600 pixels is pretty damn big! Constraining with HTML does
nothing to reduce the large files size of such images so the whole file
must be downloaded, a real pain on dialup and a real waste of bandwidth

Try something like IrfanView freeware that can batch size images
http://www.irfanview.com/
 
P

Pascal Herczog

Jonathan N. Little said:
Well actually your should! Images at resolutions meant for printing
(thousands of pixels on a side) are not really suitable for use on the web
where 600 pixels is pretty damn big! Constraining with HTML does nothing
to reduce the large files size of such images so the whole file must be
downloaded, a real pain on dialup and a real waste of bandwidth

Try something like IrfanView freeware that can batch size images
http://www.irfanview.com/

Thanks.

The picture files are not that big to start with, but resizing might be the
only option it seems. I have no real experience of java scripts (except a
few bits I've borrowed from examples), and it looks like the table
data/anchor syntax does not support setting a size for target jpg (???).
I've tried adding a width parameter but it has no effect.

Pascal.
 
J

Jonathan N. Little

Thanks.

The picture files are not that big to start with, but resizing might be the
only option it seems. I have no real experience of java scripts (except a
few bits I've borrowed from examples), and it looks like the table
data/anchor syntax does not support setting a size for target jpg (???).
I've tried adding a width parameter but it has no effect.

Not sure what your doing there, but resampling the images will result in
far 'clearer' result then the pixel dropping method use by the browser...
 
B

brucie

What I would like to do is constrain the size (width, height) of the actual
picture shown in the bottom frame when the user clicks on the text
"Airplane".

with only a few exceptions you should only display images at their actual
size. browsers are crap at resizing and you waste your visitors
time/bandwidth/money making them download an image that may be too big.

how about offering a few different sizes of the images so the visitor can
select the size they want? if you don't want to do that then use small
images and resize up but then you get icky poo looking images.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,901
Latest member
Noble71S45

Latest Threads

Top