JS Question???
Alright, I am trying to figure this one out. I have some thumbnails that when clicked on, give a larger picture. Now I really didn't want to create a page or a template page for these pictures. So I thought that I would use something like this:
<?php
function newWindow(hobbywin) {
mapWindow = window.open(hobbywin, 'mapWin', 'width=500, height=380, left=200, top=0')
mapWindow.focus()
}
and then call the function in the links by such:
<A href=\"javascript:newWindow('/images/picture.jpg')\">
?>
Well there are several problems with this. One is that since you are just calling an image and not a page, you have the margins to worry about. Another problem is that it doesn't work quite as well in NS and Opera since the window is huge. Another problem is that there is no close button.
Any ideas on this one?
Mark Irving
I have a mind like a steel trap; it is rusty and illegal in 47 states
Jack Michaelson posted this at 15:17 — 21st February 2002.
He has: 1,733 posts
Joined: Dec 1999
In stead of a popup window I used a hidden and set the display to 'visible' onmouseover/onmousedown on this page.
Hope it helps.
mmi posted this at 16:47 — 21st February 2002.
They have: 457 posts
Joined: Jan 2001
hey Jack - does that work in N6? - I'm getting an error:
Error: ImgScreenshot is not defined
Source File: http://www.ruudonline.net/new/pez/other.js
Line: 10
Web Xpertz Community Forums for Webmasters & Developers
Where You Can Learn, Advise, and Have Fun in the Process
Jack Michaelson posted this at 17:52 — 21st February 2002.
He has: 1,733 posts
Joined: Dec 1999
Oops, I forgot to mention... only IE for the moment.
Anyway mairving,
to make close button, does this work:
<?php
...
mapWindow = window.open(hobbywin, 'mapWin', 'width=500, height=380, left=200, top=0')
mapWindow.document.write(\"<html for the close button>\");
...
?>
just guessing not testing,
Shakespeare: onclick || !(onclick)
mmi posted this at 18:20 — 21st February 2002.
They have: 457 posts
Joined: Jan 2001
Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.