Web Design Question

Sigma

Member
Aug 12, 2002
418
0
16
New York
Ok, im starting to make myself a website. The thing i would like to know how to do is that on my gallery page, i have all my thumbnails etc. After i make the thumbnails into links for new windows with the pic, how do i make it into a javascript window that fits the pic according to its size. I see it on everyone's art site, i would just like to know how to do this as well.

Note: im new to this :/
 
here is one possibility:

<a href="#" onClick="window.open('file.html','_blank','width=400,height=100,directories=no,location=no,menubar=no,scrollbars=no,status=no,toolbar=no,resizable=no,left=10,top=10')">Click this</a>

the most is optional,

<a href="#" onClick="window.open('file.html','_blank','width=400,height=100,left=10,top=10')">popup2</a>

works, too. change "file.html" to the file you want to open, "_blank" is the so called "Target". "_blank" is HTML-Standart and opens always a new window. if you change this to e.g. "mywindow", the next window (with the target "mywindow") won´t open a new window. the rest should be clear. just try, it´s not difficult!
 
with PHP it´s possible to read the images size and write the javascript according to its size. but PHP is not for beginners...

<?
$size = getimagesize("images/image.jpg");
$width = $size[0];
$height = $size[1];
?>
<a href="#" onClick="window.open('file.html','2','width=<?echo $width?>,height=<?echo $height?>,left=10,top=10')">Click this</a>