Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Irritating gap/border

Status
Not open for further replies.

MarcLodge

Programmer
Feb 26, 2002
1,886
GB
Hi All,
I've got a minor problem. I'm trying to have a number of small photos on the page, and when you click on them they go to big photos. Everything's working fine except when the big photo is displayed, there's a small border at the top, and the left hand side. And I have no idea why. I've coded border = 0 to no avail. Code is:
<SCRIPT LANGUAGE=&quot;javascript&quot;>
<!--
// open new window
function newWindow(img, wide, tall)
{
imgWin = window.open(img, &quot;picture&quot;, &quot;width=&quot; + wide +&quot;,height=&quot;+ tall)
imgWin.focus()
}
// -->
</SCRIPT>
 
and the other bit is (!)

<A HREF=&quot;javascript:newWindow('images/bphoto1.jpg','361','506')&quot;>
<IMG SRC=&quot;images/sphoto1.jpg&quot; WIDTH=&quot;97&quot; HEIGHT=&quot;136&quot; BORDER=&quot;0&quot; ALIGN=&quot;TOP&quot;></A>

The size of the jpg's matches the actual size of the jpgs, if you see what I mean.
 
The difficultly you are encountering stems from the default settings of the all Windows based internet browsers. An image opened up by itself in a browser has this border (Mac browsers do not). I'd suggest altering your script to add 10-15 pixels to the width & height of the new window to compensate.

Hope this helps.

Cullen
Graphics Artist / Web Designer
cullen@ulanji.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top