| Home | Tutorials | Forums | Articles | Blogs | Movies | Library | Employment | Press | Buy templates |
|
|
#1 |
|
Registered User
Join Date: Jan 2001
Posts: 3
|
I'd like to be able to have a button in my Flash movie open a new browser window containing a plain 'ol html page. I don't want the new browser window to have anything but scrollbars and I want to be able to control the size of the new browser window. I tried tutorial #5 "Spawning external browser windows" but all I got was a new browser window with all of the javascript in the address bar. When I copied and pasted the code like it said there were lots of weird spaces PLUS I wasn't exactly sure WHERE to paste the code.
Can someone please help!? Thanks, Lori |
|
|
|
|
|
#2 |
|
Registered User
Join Date: Jan 2001
Location: Sydney, Australia
Posts: 37
|
Same problem here. Anyone help ?
|
|
|
|
|
|
|
|
|
#3 |
|
Registered User
|
You can use this way
In HTML in "HEAD tag" add following code: <script language="JavaScript"> <!-- hide from JavaScript-challenged browsers function openWindow(url, w, h) { var windowprops = "width=" + w + ",height=" + h; popup = window.open(url,'remote',windowprops); } // done hiding --> </script> Now for the action to the Flashed Button Get url JavaScript penWindow("your.html","100","250") |
|
|
|
|
|
#4 |
|
Registered User
Join Date: Jan 2001
Posts: 3
|
Strok,
Is the spacing in the javascript critical? Does the code in my html have to look EXACTLY like the code you shared with us - weird spaces and all? Also, where do you put the window attributes such as size, scrollbars, etc?? Thanks, LV |
|
|
|
|
|
#5 |
|
Registered User
Join Date: Jan 2001
Posts: 3
|
Forgot to mention I'm using Flash 4...
|
|
|
|
|
|
#6 |
|
Administrator
Join Date: Nov 2000
Location: Australia
Posts: 8,612
|
Sorry everyone, I've founda flaw in the tutorial. i obviously pasted the code incorrectly.
See it working Get the source The code generator works fine but the HTML you should put between your head tags is this: <script language="JavaScript"> <!-- function spawnWindow(URL,Name,features) { window.open(URL,Name,features); } //--> </script> I'll fix up the tutorial today. Thanks for pointing it out! Cheers Jesse
__________________
Cheers Jesse Stratford ActionScript.org Cofounder Email: presented in this way to stop spam-bots: My email is composed of my first name (jesse) followed by my last name (stratford) followed by @ followed by actionscript.org Please don't email or PM me Flash questions, that's what the Forums are for! ![]() Please don't rely on me reading my PMs either. Email me about important stuff. |
|
|
|
|
|
#7 |
|
Registered User
Join Date: Jan 2001
Location: Sydney, Australia
Posts: 37
|
Thanks for the help/fix-up Jesse. Superb.
|
|
|
|
|
|
#8 |
|
Friar Tuck's eternal meal
Join Date: Oct 2003
Location: Ontario, Canada
Posts: 343
|
When I open a new window with javascript, and set "location='no'", it merely makes the Address Bar unselectable and unchangeable.
I would like to be able to hide the Address Bar completely - is this possible? |
|
|
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Tutorial for Launching a Centered Pop-Up Window | vazbo | ActionScript 1.0 (and below) | 6 | 09-11-2009 11:19 PM |
| Controlling Browser Window via Flash Javascript buttons [via 'get url' statement]. | cheeky_monkey | ActionScript 1.0 (and below) | 7 | 01-20-2009 03:30 PM |
| FLV playback pauses when scrolling browser window | kris_mcl | Components | 3 | 07-17-2006 06:38 PM |
| movies that scale to fit the browser window | thesquirrel | Other Flash General Questions | 1 | 05-10-2006 02:55 PM |