Home Tutorials Forums Articles Blogs Movies Library Employment Press
Old 01-19-2001, 06:13 AM   #1
lvalesko
Registered User
 
Join Date: Jan 2001
Posts: 3
Exclamation

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
lvalesko is offline   Reply With Quote
Old 01-19-2001, 08:46 AM   #2
GoldRain
Registered User
 
Join Date: Jan 2001
Location: Sydney, Australia
Posts: 37
Cool

Same problem here. Anyone help ?
GoldRain is offline   Reply With Quote
Old 01-19-2001, 02:14 PM   #3
Strok
Registered User
 
Join Date: Nov 2000
Location: Toronto Canada
Posts: 798
Send a message via ICQ to Strok
Default

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 JavaScriptpenWindow("your.html","100","250")
__________________
My photography: http://strok.photosight.com
Strok is offline   Reply With Quote
Old 01-19-2001, 05:10 PM   #4
lvalesko
Registered User
 
Join Date: Jan 2001
Posts: 3
Default

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
lvalesko is offline   Reply With Quote
Old 01-19-2001, 05:12 PM   #5
lvalesko
Registered User
 
Join Date: Jan 2001
Posts: 3
Default

Forgot to mention I'm using Flash 4...
lvalesko is offline   Reply With Quote
Old 01-19-2001, 10:13 PM   #6
Jesse
ActionScript.org Founder
 
Jesse's Avatar
 
Join Date: Nov 2000
Location: New York
Posts: 8,736
Default

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

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.
Jesse is offline   Reply With Quote
Old 01-20-2001, 02:23 AM   #7
GoldRain
Registered User
 
Join Date: Jan 2001
Location: Sydney, Australia
Posts: 37
Default

Thanks for the help/fix-up Jesse. Superb.
GoldRain is offline   Reply With Quote
Old 03-14-2007, 07:53 PM   #8
FlashBulb
Friar Tuck's eternal meal
 
FlashBulb's Avatar
 
Join Date: Oct 2003
Location: Ontario, Canada
Posts: 411
Default

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?
FlashBulb is offline   Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Tutorial for Launching a Centered Pop-Up Window vazbo ActionScript 1.0 (and below) 9 01-01-2010 11:01 PM
Controlling Browser Window via Flash Javascript buttons [via 'get url' statement]. cheeky_monkey ActionScript 1.0 (and below) 7 01-20-2009 02:30 PM
FLV playback pauses when scrolling browser window kris_mcl Components 3 07-17-2006 05:38 PM
movies that scale to fit the browser window thesquirrel Other Flash General Questions 1 05-10-2006 01:55 PM


All times are GMT. The time now is 12:31 AM.

///
Follow actionscriptorg on Twitter

 


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Ad Management plugin by RedTyger
Copyright 2000-2013 ActionScript.org. All Rights Reserved.
Your use of this site is subject to our Privacy Policy and Terms of Use.