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

newBrWindow with Flash button

Status
Not open for further replies.

ironworks

Technical User
Oct 13, 2001
16
US
I am trying to make a flash button do what I've always done with JavaScript, open a new browser window of a specific dimension with an .htm of my choice. This is it in JS:

//Script for window to open another window
<script language=&quot;JavaScript&quot;>
<!--
function MM_openBrWindow(theURL,winName,features) { //v2.0
window.open(theURL,winName,features);
}
//-->
</script>

<body>
<p align=&quot;center&quot;><a href=&quot;#&quot; target=&quot;_self&quot;
onMouseDown=&quot;MM_openBrWindow('newWindow.html','','width=100,height=400,top=165,left=575')&quot;></a></p>


//Script for new window

<HTML>
<HEAD>
<SCRIPT LANGUAGE=&quot;JavaScript&quot;>
theUrl = 'newWindow.html'
lockU = 1
function doAgain() {
if (lockU == 1) {
reWin=window.open(theUrl)
}
}
</script>

</HEAD>

<BODY>
<a href=&quot;javascript:lockU=0;self.close()&quot;></a>
</BODY>
</HTML>

Now, how do I make flash do the same thing? What's the code to put in the button param's after:

on (press) {
getURL (&quot;archMenu.htm&quot;, &quot;_blank&quot;);
}


ironworks [:)) (plaintext emoticon: raised eyebrow guy)
 
Like this:

on (press) {
getURL (&quot;javascript:MM_openBrWindow ('newWindow.html', '', 'width=100, height=400, top=165, left=575');&quot;);
} Regards
David Byng
bd_logo.gif

davidbyng@hotmail.com
 
Thanks David!
Sorry it took me so long to get back. I was dying of the flu.
Now I tried your code, and it looks beautiful and clean, and logical, but alas, it didn't work!
Now what?

ironworks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top