Hello,

I have a swf file with a multiple buttons in it. When a user clicks a button, he is sent to a specific link depending on the button. Is there a way for PHP to open the swf file, and somehow change the button links to another address?
Unfortunately editting the swf file directly with Flash is not an option for me. PHP, javascript, html are all i have to work with =(

Any help would be appreciated.
Thanks!

    no
    Instead of a flash, you should just use picture links which can be changed by php

      Why not have the SWF read parameters from the HTML (there is a way of doing this), and use that to set the link URL in the Flash?

      It's much easier to make the Flash read parameters than it is to dynamically modify the SWF.

      Mark

        Thanks for the quick replies guys. However I cannot edit the swf file with flash (it is being uploaded to me by other users). I've tried reading in the .swf file, and changing the link using str_replace. When i output the string again, it is identical to the original (with all the weird characters) except for the link that i changed.

        The problem occurs when i save the swf. The button (with the new link) dissapears from the new .swf file.

          Write a Reply...