Welcome, Guest
  • Author Topic: opening new browser window  (Read 1221 times)

    kyla

    • Server what's that
    • *
    • Posts: 11
      • View Profile
      • Email
    opening new browser window
    « on: 04/14/04, 13:21 »
    So I'm doing a web page where the index contains a flash movie that has a pretty little pic and an enter button.  
    I want to be able to click on the enter button and have it open another browser window (with specific width and height) which contains another flash movie.
    I know you have to use javascript to open a new window within the index page, but how do you get javascript and flash to communicate with each other?
    What code do you use in flash? java?

    I hope this is understandable.
    Any help or comments are greatly appreciated.

    Thanks
    -kyla

    prasad gvss

    • Seasoned Programmer
    • ***
    • Posts: 124
    • India
      • View Profile
      • Telugu Entertainment
      • Email
    Re:opening new browser window
    « Reply #1 on: 04/15/04, 04:36 »
    hi

    This could be a simple and crude solution,

    for the button you can give

    on(press){
    getURL("http://whatever.com/whatever.html","_blank");
    }

    now in your  whatever.html file you can embed the swf of your choice.
    in the html code you can use javascript to resize the window. just make sure that
    your new flash movie is atleast of the size of the new window :).

    Hope this is what you want.

    Cheers,
    pessi..

    Prasad Gurla,
    Ph.D student in Materials Science,
    Aachen,
    Germany.

    kyla

    • Server what's that
    • *
    • Posts: 11
      • View Profile
      • Email
    Re:opening new browser window
    « Reply #2 on: 04/15/04, 21:26 »
    nice. It worked.  
    That was easy.
    Everything I looked at was a jumbled mess of confusion.
    Thanks.

    -ky

    kyla

    • Server what's that
    • *
    • Posts: 11
      • View Profile
      • Email
    Re:opening new browser window
    « Reply #3 on: 04/15/04, 21:40 »
    but I still want to add javascript properties to the new window I'm opening like:
    "width=800, height=400 menubar=no, status=no, scrollbars=no, resizable=no"
    but flash automatically adds all that in.

    -ky

    prasad gvss

    • Seasoned Programmer
    • ***
    • Posts: 124
    • India
      • View Profile
      • Telugu Entertainment
      • Email
    Re:opening new browser window
    « Reply #4 on: 04/16/04, 02:58 »
    hi

    did you try using the button code generator at flash-db?

    http://www.flash-db.com/PopUp/

    just generate the code and up it for the button you are using.

    pessi..
    Prasad Gurla,
    Ph.D student in Materials Science,
    Aachen,
    Germany.

    kyla

    • Server what's that
    • *
    • Posts: 11
      • View Profile
      • Email
    Re:opening new browser window
    « Reply #5 on: 04/16/04, 09:55 »
    Thanks I'll play around with it.

    kyla

    • Server what's that
    • *
    • Posts: 11
      • View Profile
      • Email
    Re:opening new browser window
    « Reply #6 on: 04/18/04, 19:44 »
    I used the code generator and everything works fine.
    Except now when my new window opens, I get another window that comes along with it.
    This window has nothing in it except the word [object] and the url address displays the code for the button.
    Any ideas?

    thanks,
    ky