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 Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Pop up problem

Status
Not open for further replies.

Ragol1

Programmer
Oct 25, 2001
315
US
I use this code to display a picture but it always show white are to the left and to the top, can I make it lets say top/0 and left/0
if so please help

Nick
<SCRIPT>
function popUp1(URL1) {
New1 = open(URL1 , &quot;New1&quot;, &quot;toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=300,height=240,screenX=200,screenY=200,left=200,top=200&quot;);
}
</SCRIPT>
 
<SCRIPT>
function popUp1(URL1) {
New1 = open(URL1 , &quot;New1&quot;, &quot;toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=300,height=240,left=0,top=0&quot;);
}
</SCRIPT>

??
 
A little confused on what you mean by white to the left and top. where do you want the popup placed? in the upper left corner? then take out screenX, screenY and set top and left to 0, 0 A language that doesn't affect the way you think about programming is not worth knowing.
admin@onpntwebdesigns.com
 
NO I can place the picture and even change the size of the box but when the picture displays in the box where ever on the screen it may be, there is a little white above it and to the left of it.
Like the top align and left align on a page.
Even if I make the box the same size as the picture it still does it. Its like I need to add topalign=0 and leftaligin=0

Thanks
 
when you set the width and height to the image how did you do it. this will take out all the white spaces unless the image itself has them.
myImage = &quot;image.gif&quot;
winWidth = myImage.width;
winHeight = myImage.height;

then replace the width and height with these two variables A language that doesn't affect the way you think about programming is not worth knowing.
admin@onpntwebdesigns.com
 
Where do I add that in this?

Thanks

<SCRIPT>
function popUp1(URL1) {
New1 = open(URL1 , &quot;New1&quot;, &quot;toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=300,height=240,screenX=200,screenY=200,left=200,top=200&quot;);
}
</SCRIPT>


<a href=&quot;javascript:popUp1('../images/bjorn/01_01.jpg');&quot; onMouseOut=&quot;MM_swapImgRestore()&quot; onMouseOver=&quot;MM_swapImage('Image13','','../Images/bjorn/01_01hg.jpg',1)&quot;><img src=&quot;../Images/bjorn/01_01sm.jpg&quot; name=&quot;Image13&quot; border=&quot;0&quot;></a></td>
 
try this
<SCRIPT>
function popUp1(URL1) {
winWidth = URL1.width;
winHeight = URL1.height;
New1 = open(URL1 , &quot;New1&quot;, &quot;toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=&quot;+winWidth+&quot;,height=&quot;+winHeight+&quot;,screenX=200,screenY=200,left=200,top=200&quot;);
}
</SCRIPT>
A language that doesn't affect the way you think about programming is not worth knowing.
admin@onpntwebdesigns.com
 
note:
I've never used this with a path as you are. It may not read the iamge correctly. but it may work, no time to test it as is here. sorry I didn't realize you were calling it likeyou are A language that doesn't affect the way you think about programming is not worth knowing.
admin@onpntwebdesigns.com
 
No it doesnt work its really tall and has more white to the right of the picture.

How do you suggest calling it then

Nick
 
What about making the white a different color like #333333

Nick
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top