Flash button script to control browser window

I would like to open a browser window from a Flash button
which will open my .swf into an html page with specific height and
width with no tool bars just like: the "click here for demo" button
in www.teachingtextbooks.com. It opens a window with no tool bars
and it fits the .swf file perfectly. I see javascript in the html
page that looks like it is part of the script however I am assuming
their is script on the button as well.
Please help.
Thanks,
Green

Thank you for your help on this. I copy and pasted your code
(on the button and I rec'd 2 errors. I copied and pasted here. I
will put the code on the frame if I can get this working.
**Error** Symbol=premier_mc, layer=angelmovie, frame=151:Line
2: ')' or ',' expected
getURL("javascript:YourWindow=window.open("
http://www.google.com",'YourWindow','width=850,height=650,left=0,top=0,toolbar=No,location =No,scrollbars=No,status=No,resizable=No,fullscreen=No');
YourWindow.focus(); void(0);");
**Error** Symbol=premier_mc, layer=angelmovie, frame=151:Line
3: Unexpected '}' encountered
Total ActionScript Errors: 2 Reported Errors: 2
Frame 151 is where the button is and there is only 3 lines of
code in the Action Script panel. Any idea why I am getting the
error. I won't have to add code to the html page?
Thank you.

Similar Messages

  • Want To Have Flash Project Open In New Browser Window

    Hi,
    My project outputs and plays perfect to Flash (let default to
    Flash 7) but when viewing it (via a link from a web page) it opens
    in a "next" window and at the end, if you use the X (EXIT) button
    from the player control bar it wants to close the browser window
    and does not take you back to the webpage (where I have the link to
    play). I cannot seem to find an option in the Preferences or during
    output to make the player open in a "new" browser window. Is it
    possible there is a browser setting for this instead of setting in
    Captivate? (IE 6 or 7) Thanks for any help/suggestions!

    Hi leh1, and welcome to the User Community for Captivate!
    The window in which any content plays is determined by the
    code contained for the link,
    in the web-page from which it is launched. In a nutshell,
    you add these parameters to the link when it is created in the
    "Parent" window.
    Below is a snippet from a Menu Builder project in which the
    links to "Project1" and "Project2" are set to open in a "New"
    window, without chrome (note the many "
    =no" following an equal sign), at a size of 720 pixels by
    540 pixels ... the snip below shows a link to "Project1.htm", a
    document containing a Captivate movie. I have bolded the specific
    entries that control the type window ("OpenCustomLink") and the
    size of that window ("width=720,height=540"):
    <P style="cursor: pointer; cursor: hand; position:
    absolute; left: 90px; top: 149px; text-decoration: none; font:
    normal 18pt Arial; color: #000000" title="Project 1" onclick="
    OpenCustomLink('project1.htm', '_blank',
    'scrollbars=no,status=no,
    titlebar=yes,toolbar=no,menubar=no,location=no,resizable=yes,
    fullscreen=no,
    width=720,height=540'); "
    onmouseover="this.style.color='#0000FF'; "
    onmouseout="this.style.color='#000000';">Project 1</P>
    (some spaces inserted to avoid horizontal scroll)
    All of which is to say, the target window is controlled from
    the link in the parent document. I wouldn't suggest you just
    copy-paste the above code, as I took liberties with it. I
    would suggest that you can do this yourself with your own
    HTML editor (Dreamweaver, etc.), or even better, get your local
    web-guru to do it for you.
    All the best!!
    .

  • Controlling Browser Window Options

    Hi,
    I have published swf files from Captivate and uploaded them
    on a server, then published the links to the files as URL's for
    customer to view the movies in a browser. These links are either
    provided as a clickable link or button in a web page or as a
    clickable bookmark.
    I want to edit the HTM file generated by Captivate to control
    how the browser opens.
    In one case I want to change the HTM to open matching the
    movie size and without any toolbars, menu bar etc. In the other
    case I want the browser to open in a separate window sized to the
    movie and without toolbars etc.
    I have tried inserting the following JAVA Script:
    <SCRIPT LANGUAGE="javascript">
    <!--
    window.open (config='height=100,width=400, toolbar=no,
    menubar=no, scrollbars=no, resizable=no,location=no,
    directories=no, status=no')
    -->
    </SCRIPT>
    Which only resizes the window in IE does nothing in Firefox.
    What am I doing wrong?
    Thanks
    Claire

    no back button? you mean there's no browser?

  • Making buttons link to popup browser windows in ActionScript 3

    I am trying to figure out how to make buttons on my flash
    file link to URLs that appear in a window of fixed dimensions (with
    scroller bars) next to my Flash window.
    I am aware that Adobe has instructions for creating pop-up
    browser windows through Flash (
    http://kb.adobe.com/selfservice/viewContent.do?externalId=tn_14192)
    However, what I'm trying to do is a bit more complicated,
    since I want to have multiple embedded invisible buttons in the
    Flash window that each take you to a specific URL when you click on
    them. Alternatively I'd be happy if any button click resulted in a
    link to a random selection from a pre-programmed list of URLs.
    Any suggestions? This is for ActionScript 3.

    Hi Im having a simlar problem with creating a button that
    opens up a url link in a blank browser window and keeping it at a
    specific size. here is the code that I'm using.
    my_btn.addEventListener(MouseEvent.MOUSE_DOWN,
    mouseDownHandler);
    function mouseDownHandler(event:MouseEvent):void {
    var urlStr = "my info_page.html";
    if (ExternalInterface.available) {
    ExternalInterface.call( "window.open", urlStr, "_blank",
    "width=400,height=400");
    } else {
    var urlRequest:URLRequest = new URLRequest(urlStr);
    navigateToURL(urlRequest);
    the problem is the window doesn't open when I click on the
    button and I don't know how to fix this

  • Opening an URL via a button in a new browser window?

    Hello,
    I'm integrating now Oracle Reports in my HTML DB application.
    Everything work well. I have create a launching page with paremeter items and a button that call a branching of type "Branch to Function Returning a URL". This branching construct the Oracle Report URL with parameters as entered in the parameter page.
    The only thing missing is the possibility to open Report output in a different browser window. I don't know how to do it via the Branching specification. Normally, in HTML, I would use target="_new" .
    Thank you
    Jean

    you might want to try having your page submit as normal, doing your parameter manipulation in an after_submit pl/sql process, and popping up the report page from your next htmldb application page. let's say, for example, that you have an update form on page 4 that branches back to a report page 2 in your application. you'd like to use the P4_JOB value submitted from page 4 to pop up a google search for that job and the string "oracle". you could do it like this...
    --create an app-level (or page level) item called POP_ON_LOAD
    --have page 4 submit as normal and branch back to page 2
    --add a pl/sql process that fires when page 4 is submitted.  have that proc set the value of POP_ON_LOAD like so...
    begin
    :POP_ON_LOAD := 'OnLoad="popupURL(''http://www.google.com/search?q=oracle+&P4_JOB.'');"';
    end;
    --enter &POP_ON_LOAD. into the "Page HTML Body Attribute" attribute of the "On Load JavaScript..." region on the page-level attributes page for page 2.
    this way, when POP_ON_LOAD is populated, htmldb will make the onLoad call to popupURL passing in whatever url you set from your after_submit process on page 4. and just remember to clear your POP_ON_LOAD item when you don't want page 2 to pop up those extra windows.
    hope this helps,
    raj

  • Problems with Flash video streaming in any Browser (Windows 8.1)

    Hello.
    Since maybe the last Chrome update (to version 42.0.2311.90 m - I tried both 32 and 64 bits versions) or some Windows 8.1 updates (I don't know for sure), flash videos don't even start to buffer - they only play after the full content is downloaded (or loaded in the site's player) . So, If I try to watch a video from a Flash Player based interface (like Dailymotion, or Vimeo), I have no streaming, and I have to wait a long time, watching a "1%" or a load wheel until the full content is available to watch.
    This is happening with all browsers, not only Chrome (IE and Firefox too). I tried to update flash player (first, version 17,0,0,169 and then tried the beta, the one released April 14, 2015). No difference at all. So, I think this might be a problem with the flash player itself, or with some Windows settings.
    So, lets go to the facts:
    - That happened suddenly for no apparent reason - one day it was working, and on the other day it wasn't;
    - I have the latest versions of all browsers I use (Chrome, IE and Firefox);
    - My Flash Player version is, currently, the latest version;
    - I tried old Flash Player versions. didn't work;
    - This is not happening with HTML5 video players, like Youtube, so i think it's not a codec problem;
    - I have the latest nVidia graphics driver. And it was happening even before I update the driver (I have a GeForce GTX 770);
    - I tried disabling the hardware acceleration on Flash settings, nothing happened;
    - I use default Windows Firewall and Defender. Tried to disable firewall, nothing happened;
    - I had searched all over the internet for the answer, but I can't find it. I already did all what the troubleshoot pages from Adobe said to do;
    - My internet connection is fine. It's a fast connection, and It's on wireless. I have several PCs connected to this network and flash videos work fine with them, only in this specific machine isn't;
    - I tried uninstall flash player and install again several times, with several different versions. Didn't work;
    - Tried disable different versions of flash player on Chrome too, nothing happened.
    The thing is, I can imagine that this might not be only a flash player problem, but since it's the only plugin problem I have, I thought that you might have the answer.
    Thank you.

    Please work through the video troubleshooting guide.
    https://helpx.adobe.com/flash-player/kb/video-playback-issues.html
    If you're still stuck, please follow the directions in the guide on providing the dxdiag report and additional information about what you tested and saw.

  • Is it possible in firefox to close a browser window/tab using java script without modifying the configuration settings? If YES, please let me know.

    Requirement: On click of button, I want the browser window to be closed.
    Solution: I am calling below java script on "onClick()" event of button.
    function close_window()
    window.close()
    This works in internet explorer but not in Mozilla Firefox. What is the reason behind it. Is there any way out to close the browser window in Mozilla Firefox?

    Can you post a link to a page that opens a pop-up window where a close button doesn't work?
    Start Firefox in <u>[[Safe Mode|Safe Mode]]</u> to check if one of the extensions (Firefox/Tools > Add-ons > Extensions) or if hardware acceleration is causing the problem (switch to the DEFAULT theme: Firefox/Tools > Add-ons > Appearance).
    *Do not click the Reset button on the Safe mode start window or otherwise make changes.
    *https://support.mozilla.org/kb/Safe+Mode
    *https://support.mozilla.org/kb/Troubleshooting+extensions+and+themes

  • How to center flash movie in browser window

    Can anyone explain how to horizontally center my Flash movie in the web browser window after publishing?
    A bit of background:
    I was able to achieve this using <center></center> tags a few years ago. But I have since upgraded to CS5 and I understand that this old method is now obsolete.
    I have found a few threads/forums that address this, but I know nothing about HTML and these threads don't help me because they assume you have more knowledge than I possess. When opening up the index.html file in Dreamweaver I can't find anything that looks vaguely familiar to what is being discussed. I have found some code samples using <div></div> tags but have no idea where to place it.
    So I will need it explained to me in a step by step fashion, including which file I need to fix and what program I should use. Code samples will be very welcome if you can tell me exactly where it goes.
    Thanks in advance...

    Just realized that there is no scrolling functionality with the .swf generated from the new CS5. Can anyone help out by providing revised code for centering and scrolling?
    I found something elsewhere in the forums that worked for both centering and scrolling that worked fine yesterday, but upon visiting my site today for testing, it did not allow the scrolling, and centering did not work in Firefox. Tested both Safari and Firefox on 2 Macs running Snow Leopard.
    Again, much appreciated - nice to visit forums where people are interested in helping instead of screaming at each other. Will visit the Illustrator or Indesign forum to see if I can help out someone there...

  • How to centre Flash content in browser window?

    Hi there
    I'm relatively new to Flash, so maybe there's a simple answer to this one.
    How do I centre my Flash content horizontally in the browser window? In the Publish Settings I see there are options to align the HTML to Default, Left, Right, Top and Bottom, but no Center. Is there a setting somewhere else? Do I need to write some ActionScript to do this? (If so, what?)
    I'd appreciate any suggestions.
    (I'm using CS3 on a Mac.)

    OK, I'm fumbling around a bit here. I see now that the Flash content does resize to fit the window. So, back to my original question: how can I get it to keep its original size but stay centered horizontally in the window?
    Any advice would be greatly appreciated.

  • Can't find a java script that will close browser window

    I went through the archives and found several java scripts
    for closing browser windows. Unfortunately none of the work. If I
    find one that will work on a Mac - Safari then it won't work on a
    PC - IE. I downloaded and installed that extension but cannot find
    it on my Mac menus. Running MX2004 on a Mac.
    Here are the codes I've tried and a example page:
    <a href="#" onClick="window.close()">close
    window</a>
    <a href="javascript:window.close();">{YOUR TEXT
    HERE}</a>
    <a href="javascript:window.close()">Click here to close
    this
    window</a>
    <a href="javascript:self.close();"> close window
    </a>
    Here's an example of a non working page:
    [removed to protect the company]
    and another script that doesn't work:
    [removed to protect the company]
    Thanks for all your help.

    phrarod wrote:
    > I came here to learn. It was a simple thing and I was
    embarrassed that I forgot
    > how to do it. I mentioned that. I thanked Alan. My
    friend owns that company.
    > He's trying to help me out. He's a great guy and helps
    people alot. He doesn't
    > rip anyone off or pay them a pittance. He doesn't do a
    ton of web work because
    > as you said its harder and harder to get any money since
    clients have to be
    > educated why they need you when they can get it for free
    or $300 or a couple
    > hundred. We're all trying to make a living. If someone
    helps me I want to repay
    > that help if I can. I know I'm not paying for the advice
    here and since its in
    > a forum I don't know about I can't help technically.
    Networking is always a
    > good thing. I tried to help by offering a lead. How do
    you know this person
    > doesn't pay much? Because of me? Rather than following a
    lead you just assumed.
    > I know a lot about print and TV. I'm trying to fill out
    my skill-set to offer a
    > wider range of services. End of rant. I'm just hurt I
    was stepped on as it
    > blind-sided me. I have a solution. If its so basic it
    upsets the people who
    > answer then don't answer.
    >
    Don't feel offended, the comments weren't directed at you,
    rather at the
    bizarre world of web design.
    :-) We need to hang tough and help each other, whether we're
    working
    for a decent salary, for a pittance, or for our middle-aged
    aunt.
    Bonnie
    in California
    8 ^ )

  • Click button to close browser window

    What javascript can I use with a button to close the browser
    window without poping up a window asking the user "Do you want to
    close this window?"

    Welcome to our community, Yohanski
    See if the following link helps.
    Click
    here
    Cheers... Rick

  • Dreamweaver Flash Buttons Paths

    Hello all,
    I am a novice site designer. My first challenge is to design a navigation bar once and used by all web pages.  I built it using Flash buttons.  The concept works fine in a flat file, but when I'm viewing a web page that sits in a different directory than the flash navigation buttons, the buttons point to a file in the current directory which doesn't exist. I want the buttons to still point to the flash files in the parent directory.
    I'm using Dreamweaver CS2 to create my flash buttons. I'm using PHP include statements to include my flash navigation bar. When I create the php file in another directory, click on flash button, all heck breaks loose. I look at the URL and the link appends the PHP file that the flash button should be pointing to whatever directory my current web page is in.
    It seems like, I should just create each button  as a absolute path, http://rootdirectory.com/filename.php, but it still uses relative path when I'm looking at web page that sits in another directory and appends the navigation link to the current directory http://rootdirectory.com/currentdirectory/filename.php although it points to a link in the root or parent directory.
    Do I not know how to create flash buttons using the absolute paths?

    If you want to use Flash for navigation, consider this -
    1. Some people don't have Flash installed - what do they do?
    2. Search engines don't parse Flash links - your site will
    not be spidered
    3. Screen assistive devices don't parse Flash links - what
    will those users
    do?
    4. DW cannot maintain links within a Flash movie, so if you
    move or rename
    a linked file, your navigation will break - what will you do?
    It's usually a very bad idea for these reasons...
    Adding in frames makes it even worse - you are in the deep
    stuff here. Why
    are you using frames?
    Murray --- ICQ 71997575
    Adobe Community Expert
    (If you *MUST* email me, don't LAUGH when you do so!)
    ==================
    http://www.dreamweavermx-templates.com
    - Template Triage!
    http://www.projectseven.com/go
    - DW FAQs, Tutorials & Resources
    http://www.dwfaq.com - DW FAQs,
    Tutorials & Resources
    http://www.macromedia.com/support/search/
    - Macromedia (MM) Technotes
    ==================
    "LeichterLernen" <[email protected]> wrote
    in message
    news:er5fua$3am$[email protected]..
    > Hey, I use some standard flash buttons from Dreamweaver
    to navigate. I
    > have two
    > frames in this web. The buttons are in frame "A" and
    refer to a target in
    > frame
    > "B". This worked perfectly fine, even with IE 7 in
    Windows XP it still
    > works.
    > But in Windows VISTA every button opens a new browser
    windows.
    >
    > Windows VISTA, IE 7, Dreamweaver 8, running the web on
    my HD
    >
    > Thanks in advance.
    >
    > Sky
    >

  • Dreamweaver Flash Buttons / Frame Navigation in VISTA

    Hey, I use some standard flash buttons from Dreamweaver to
    navigate. I have two frames in this web. The buttons are in frame
    "A" and refer to a target in frame "B". This worked perfectly fine,
    even with IE 7 in Windows XP it still works. But in Windows VISTA
    every button opens a new browser windows.
    Windows VISTA, IE 7, Dreamweaver 8, running the web on my HD
    Thanks in advance.
    Sky

    If you want to use Flash for navigation, consider this -
    1. Some people don't have Flash installed - what do they do?
    2. Search engines don't parse Flash links - your site will
    not be spidered
    3. Screen assistive devices don't parse Flash links - what
    will those users
    do?
    4. DW cannot maintain links within a Flash movie, so if you
    move or rename
    a linked file, your navigation will break - what will you do?
    It's usually a very bad idea for these reasons...
    Adding in frames makes it even worse - you are in the deep
    stuff here. Why
    are you using frames?
    Murray --- ICQ 71997575
    Adobe Community Expert
    (If you *MUST* email me, don't LAUGH when you do so!)
    ==================
    http://www.dreamweavermx-templates.com
    - Template Triage!
    http://www.projectseven.com/go
    - DW FAQs, Tutorials & Resources
    http://www.dwfaq.com - DW FAQs,
    Tutorials & Resources
    http://www.macromedia.com/support/search/
    - Macromedia (MM) Technotes
    ==================
    "LeichterLernen" <[email protected]> wrote
    in message
    news:er5fua$3am$[email protected]..
    > Hey, I use some standard flash buttons from Dreamweaver
    to navigate. I
    > have two
    > frames in this web. The buttons are in frame "A" and
    refer to a target in
    > frame
    > "B". This worked perfectly fine, even with IE 7 in
    Windows XP it still
    > works.
    > But in Windows VISTA every button opens a new browser
    windows.
    >
    > Windows VISTA, IE 7, Dreamweaver 8, running the web on
    my HD
    >
    > Thanks in advance.
    >
    > Sky
    >

  • How to check if the browser window is open?

    Background:
    In my applet, I have 2 buttons: "Open" and "Close".
    When "Open" is clicked, I open a URL using:
    getAppletContext().showDocument(new java.net.URL("http://server/MyPage.html"), "MyWindow") This works fine.
    When "Close" is clicked, I want to close the previously opened browser window. For that, I am using: getAppletContext().showDocument(new java.net.URL("http://server/Close.html"), "MyWindow") In Close.html, I have used JavaScript's self.close() on OnLoad event.
    This also works fine, i.e., the previously opened browser window gets closed.
    Now the problem:
    If the previously opened browser windows is manually closed, then when "Close" button is clicked, a browser window flashes and goes off. To avoid this, I want to detect if the previously opened browser window is still open - before clicking on "Close" button. Is there a way to do this?
    thanks and regards,
    DAKAMATH

    Note that I am using self.close() in onLoad event because I am closing the same window. If the window doesn't exist, it will create (from Java) and close it (from JavaScript). So it flashes. So it is required that I need to check for browser window existance from within Java and not in JavaScript.
    thanks and regards,
    DAKAMATH

  • Input template Forms - Browser window too little

    Hi
    I have created XML Input templates using XML Forms Builder (Form Based Publishing).
    Some of the fields are fields to keep a RID with a little square browwser button attached.
    When using this browser button, a new <i>browser window</i> opens. This window is almost never the right size. The user allways have to use the mouse to draqg out the window to be able to look at all the files.
    It must be possible to control the size of that browser window?

    Hi Flemming,
    unfortunately, the size of the browser windows in XMLForms are fixed (they do not automatically resize).
    But you can define this fixed size in the configuration file at "\etc\xmlforms\XFBuilderConfig\browserControls.xml" (so normally you can set a bigger width/height to avoid manual adjustments).
    For example, you want a bigger "Date Picker" you can edit the elements <width> and <height> of this section. After that you must rebuild your XMLForms project.
    But please keep in mind, that these setting are global to all XMLForms projects. If you a rebuilding another XMLForms project, this DatePicker will also become this WindowSize.
    Kind Regards
    --Matthias

Maybe you are looking for