SitePoint Sponsor |
|
User Tag List
Results 1 to 7 of 7
Thread: window.open question
-
Jul 30, 2002, 04:24 #1
- Join Date
- May 2002
- Location
- Oslo
- Posts
- 138
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
window.open question
I copied this script from a friend:
<SCRIPT LANGUAGE="JAVASCRIPT">
function CaricaFoto(img){
foto1= new Image();
foto1.src=(img);
Controlla(img);
}
function Controlla(img){
if((foto1.width!=0)&&(foto1.height!=0)){
viewFoto(img);
}
else{
funzione="Controlla('"+img+"')";
intervallo=setTimeout(funzione,20);
}
}
function viewFoto(img){
largh=foto1.width+20;
altez=foto1.height+20;
stringa="width="+largh+",height="+altez;
finestra=window.open(img,"",stringa);
}
</SCRIPT>
How can I get the window that opens on the last line to be scrollable and resizable?
-
Jul 30, 2002, 05:47 #2
- Join Date
- Jul 2002
- Location
- Dallas, TX
- Posts
- 2,900
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Just add this line
Code:stringa="width="+largh+",height="+altez; stringa += ",scrollbars, resizable"; finestra=window.open(img,"",stringa);
-
Jul 30, 2002, 05:52 #3
- Join Date
- May 2002
- Location
- Oslo
- Posts
- 138
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
thanx
-
Jul 30, 2002, 07:36 #4
- Join Date
- Feb 2002
- Location
- Gatwick, UK
- Posts
- 1,206
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
I'm not definate about this - but i think you can
affect both those properties on an opened window.
Flawless---=| If you're going to buy a pet - get a Shetland Giraffe |=---
-
Jul 30, 2002, 16:41 #5
- Join Date
- Jan 2002
- Location
- London
- Posts
- 3,509
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Originally posted by Flawless_koder
I'm not definite about this - but i think you can
affect both those properties on an opened window.
(and even if you could how is it relevant??)MarcusJT
- former ASP web developer / former SPF "ASP Guru"
- *very* old blog with some useful ASP code
- Please think, Google, and search these forums before posting!
-
Jul 31, 2002, 01:00 #6
- Join Date
- Feb 2002
- Location
- Gatwick, UK
- Posts
- 1,206
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
So you can set them from within the browser once it's open.
That would mean less code.
And thanks for the sp correction
Flawless---=| If you're going to buy a pet - get a Shetland Giraffe |=---
-
Jul 31, 2002, 02:32 #7
- Join Date
- Jan 2002
- Location
- London
- Posts
- 3,509
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Originally posted by Flawless_koder
That would mean less code.Code:stringa += ",scrollbars, resizable";
MarcusJT
- former ASP web developer / former SPF "ASP Guru"
- *very* old blog with some useful ASP code
- Please think, Google, and search these forums before posting!
Bookmarks