Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > HTML > Picture sizing for target frames

Reply
Thread Tools

Picture sizing for target frames

 
 
Pascal Herczog
Guest
Posts: n/a
 
      11-03-2005
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.



 
Reply With Quote
 
 
 
 
Neredbojias
Guest
Posts: n/a
 
      11-03-2005
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.

--
Neredbojias
Contrary to popular belief, it is believable.
 
Reply With Quote
 
 
 
 
Jonathan N. Little
Guest
Posts: n/a
 
      11-03-2005
Pascal Herczog wrote:
> 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/

--
Take care,

Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com
 
Reply With Quote
 
Pascal Herczog
Guest
Posts: n/a
 
      11-03-2005

"Jonathan N. Little" <(E-Mail Removed)> wrote in message
news:g2gaf.1062$(E-Mail Removed)...
> Pascal Herczog wrote:
>> 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/


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.


 
Reply With Quote
 
Jonathan N. Little
Guest
Posts: n/a
 
      11-03-2005
Pascal Herczog wrote:
> "Jonathan N. Little" <(E-Mail Removed)> wrote in message
> news:g2gaf.1062$(E-Mail Removed)...
>
>>Pascal Herczog wrote:

<snip>
> 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...

--
Take care,

Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com
 
Reply With Quote
 
brucie
Guest
Posts: n/a
 
      11-03-2005
In post <news:43697b33$0$27996$(E-Mail Removed)>,
Pascal Herczog said:

> 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.


--
l i t t l e v o i c e s
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem in setting Target Node and Target Tree Property mohit ASP .Net 0 01-23-2008 05:41 AM
Multiple LCD Picture Frames - One Picture DavidL Digital Photography 1 05-09-2007 10:30 PM
[XML Schema] Including a schema document with absent target namespace to a schema with specified target namespace Stanimir Stamenkov XML 3 04-25-2005 09:59 AM
Re-sizing picture Jim L Digital Photography 16 01-27-2005 03:46 AM
Sizing Frames For example John Smith ASP General 1 08-19-2003 11:47 AM



Advertisments