Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 6 of 6

Thread: Flash - PHP

  1. #1
    Registered User
    Join Date
    Apr 2003
    Posts
    20
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Flash - PHP

    Can anyone help me to get value from database in my flash movie ?
    i am using PHP to build this . Please help. this is urgent .

  • #2
    Super Moderator
    Join Date
    May 2002
    Location
    Perth Australia
    Posts
    4,084
    Thanks
    11
    Thanked 100 Times in 98 Posts
    Do you know how to loadVariables in flash ? - if so it s the same deal .. except that instead of loadVariables('vars.txt');

    you loadVariables('http://domain.com/variables.php');

    where all that variable.php will output is the data you need in the required var=this&var2=that format.

    but get used to loading variables from a text file first , I think that flashMX automates this somewhat ? - not sure cos I never tried it but its straightforward in flash4/5
    resistance is...

    MVC is the current buzz in web application architectures. It comes from event-driven desktop application design and doesn't fit into web application design very well. But luckily nobody really knows what MVC means, so we can call our presentation layer separation mechanism MVC and move on. (Rasmus Lerdorf)

  • #3
    New to the CF scene
    Join Date
    Apr 2003
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Smile Loading variables

    You can use the following code:

    In PHP:
    PHP Code:
    $somevar="something";
    $anothervar="cool";
    print 
    "&somevar=$somevar&anothervar=$anothervar" 
    I guess something like that.
    Hope it works

  • #4
    Senior Coder missing-score's Avatar
    Join Date
    Jan 2003
    Location
    UK
    Posts
    2,194
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I think you kinda missed the point. We are talking about loading variables in flash, from PHP.

  • #5
    New Coder
    Join Date
    Jun 2004
    Posts
    15
    Thanks
    0
    Thanked 0 Times in 0 Posts
    sorry to bring this thread back, but i am interested in this...I am native to working in flash and just started working in php.....


    u can either bring it in as a string or an xml formatted documented, as of (mx) as far as I know.....what seems to be the best method?


    ne body have ne ideas?



    also one last item....


    I am working with php to make a function that creates a button out of an image:

    PHP Code:
    function display_button($target$image$alt)
    {
      echo 
    "<center><a href=\"$target\"><img src=\"images/$image".".[COLOR=DarkRed]swf[/COLOR]\" 
               alt=\"$alt\" border=0 height = 50 width = 135></a></center>"
    ;


    it cant seem to see the .swf file....is this a limitation in php....

    I now that gifs and jpegs seem to work....and the very limited png seems to work on my windows setup...

    does ne body know about this?




    Thanks,
    ~Jason

  • #6
    Senior Coder Nightfire's Avatar
    Join Date
    Jun 2002
    Posts
    4,265
    Thanks
    6
    Thanked 48 Times in 48 Posts
    PHP is nothing to do with your problem. As far as I know, you can't call flash from an img tag, you can only do it via the object or embed tag.


  •  

    Posting Permissions

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