A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: AS & Javascript

  1. #1
    Junior Member
    Join Date
    Nov 2001
    Location
    Brazil / RS
    Posts
    8

    AS & Javascript

    Somebody knows how can I use the following code(or something with the same capabilities) into a button in Flash?

    <a href="noticias.htm" target="central" onclick="window.location.href='#'">link</a>

    Tnks in advance!

  2. #2
    Senior Member Vincent26381's Avatar
    Join Date
    Feb 2003
    Location
    The Netherlands
    Posts
    833
    Hi,

    This works for a normal anchor. Maybe that helps a bit.

    code:
    on (release) {
    getURL("javascript:location.hash='#put_anchor_here '; void(0);");
    }



    Cheers,

    Vincent
    Vincent
    SWIS BV

    Last edited by Markp.com on 07-23-2003 at 02:25 AM

  3. #3
    Junior Member
    Join Date
    Nov 2001
    Location
    Brazil / RS
    Posts
    8
    Works, but there is a bug on the code!
    After 3 times pressing the button, the page crashes (I think it's somtehing related to the URL update by the JS intruction).
    p.s.: I'm using an iframe to load the pages the button is pointing for.
    Tnks

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