A Flash Developer Resource Site

Results 1 to 6 of 6

Thread: Open a new window

  1. #1
    Junior Member
    Join Date
    Jun 2006
    Posts
    9

    [F8] Open a new window

    my site works fine in flash 8 but with the new actionscript changes in flash 9, anyone who uses flash 9 on my web site it doesnt work properly.

    the problem is as follows:

    originaly the buttons were set to open a url in a new window, however that doesnt happen anymore. i used this code

    on(release){
    getURL("http://www.google.com","_blank")
    }

    please help.
    Last edited by Narm; 08-04-2006 at 01:30 AM.

  2. #2
    Senior Member
    Join Date
    Jul 2006
    Location
    Australia
    Posts
    167

    hey

    Hey, can you post the link to your site so I can check it out. Also, if you posted the source files (.fla), it would make it easier for people to help you.

    Cheers
    Ben a.k.a. Flash Geek
    Need Help? Get It Within 24 hours. If you don't have one of these messenger clients, just email me at my msn address below:
    Msn: ben" at "benmartinstudios" dot "com"

  3. #3
    Junior Member
    Join Date
    Jun 2006
    Posts
    9
    Well i yanked the original web page, and the content took too long to get to the button anyway, so i made a new fla.

    Fla

  4. #4
    Junior Member
    Join Date
    Jun 2006
    Posts
    9
    turns out it is because my page was on myspace, and well.... top screwed me.

  5. #5
    Junior Member
    Join Date
    Jun 2006
    Posts
    9
    turns out it is because my page was on myspace, and well.... tom screwed me.

  6. #6
    Senior Member
    Join Date
    Jul 2006
    Location
    Australia
    Posts
    167

    Code not most practical

    Hey, I don't know about you, but this code worked for me in adobe flash player 9. I would suggest using different code to this:

    Code:
    button1.onRollOver = over;
    button1.onRollOut = out;
    button1.onRelease = function(){
    button1.onRelease = getURL("http://www.google.com",window="_blank");
    }
    function over() {
    this.gotoAndPlay(2);
    }
    
    function out() {
    this.gotoAndPlay(11);
    }
    Try using this:
    Code:
    button1.onRollOver = function(){
    this.gotoAndPlay(2);
    };
    button1.onRollOut = function(){
    this.gotoAndPlay(11);
    };
    button1.onRelease = function(){
    getURL("http://www.google.com",window="_blank");
    }
    Hope that I helped.

    Cheers
    Ben a.k.a. Flash Geek
    Need Help? Get It Within 24 hours. If you don't have one of these messenger clients, just email me at my msn address below:
    Msn: ben" at "benmartinstudios" dot "com"

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center