2 Replies Latest reply on May 5, 2006 8:55 PM by Newsgroup_User

    include a php script

    jonnybennett Level 1
      When my site loads up, I want to run a php script. 'runScript.php'
      My swf, is embedded in my html homepage.
      I can't embedd the swf into a php page instead of html becuase this will stop search engines from finding my site.
      If it was embedded in php I could either run the script from there or use <?php include "runScript.php" ?>

      However as this is not possible I was thinking that i could make my php script run using actionscript.

      Therefore along with my preloader I could add some script to run the php script.
      but what?

      noVariable.sendAndLoad("runScript.php",noVariable,'POST');

      I don't need to send any variables, or load any, but this would run my script....
      is there not a better way??? to make the script run, without pretending to send and load variables to the php.
        • 1. Re: include a php script
          Level 7
          Have the PHP return an HTML page with the OBJECT and EMBED tag for your swf.
          This is a common application.

          --
          Lon Hosford
          www.lonhosford.com
          May many happy bits flow your way!
          "jonnybennett" <webforumsuser@macromedia.com> wrote in message
          news:e3gtqc$894$1@forums.macromedia.com...
          When my site loads up, I want to run a php script. 'runScript.php'
          My swf, is embedded in my html homepage.
          I can't embedd the swf into a php page instead of html becuase this will
          stop
          search engines from finding my site.
          If it was embedded in php I could either run the script from there or use
          <?php include "runScript.php" ?>

          However as this is not possible I was thinking that i could make my php
          script
          run using actionscript.

          Therefore along with my preloader I could add some script to run the php
          script.
          but what?

          noVariable.sendAndLoad("runScript.php",noVariable,'POST');

          I don't need to send any variables, or load any, but this would run my
          script....
          is there not a better way??? to make the script run, without pretending to
          send and load variables to the php.


          • 2. Re: include a php script
            Level 7
            >> I can't embedd the swf into a php page instead of html becuase this will
            >> stop search engines from finding my site.

            Where did you hear that? If that were true many, many sites would not be
            showing up in Google. I'd venture to say the pages of most large sites do
            not have .htm extensions. They are .asp, .jsp, .php, and .cfm - and they're
            all spidered properly as far as I know.

            What are you trying to do anyway?


            --
            Dave -
            Adobe Community Expert
            www.blurredistinction.com
            www.macromedia.com/support/forums/team_macromedia/