4 Replies Latest reply on Jan 2, 2011 6:00 AM by Kjoller



      Hey there, all!


      I have a problem reaching my php-files


      This works, if I place the file hent_billede.php in the root aswell:


      <code snippet from my flash.swf>


      </code snippet from my flash.swf>


      But I need my flash.swf to be located in the root of my server, and the php file to be placed in ./custom_inserts/flashgalleri/hent_billede.php


      So, I tried changing the .swf code to


      <code snippet from my flash.swf>


      </code snippet from my flash.swf>


      And to:


      <code snippet from my flash.swf>


      </code snippet from my flash.swf>


      And neither worked...?!


      Is there something I should know about paths, in Actionscript?


      I hope you can help.


      Thank you



        • 1. Re: Path-problem
          Ned Murphy Adobe Community Professional & MVP

          The main criteria for using a relative path in actionscript is that the path should be specified relative to the html page that loads the swf file, not the swf. IF they both reside in the same folder, then there should be no problem between testing in the IDE and live on a server.


          Normally I would just use an absolute path since the php file has to be on the server to have it function.  But for a relative path, if the swf is in the same folder as the html page that embeds it, and your custom_inserts folder is also emanates from that folder, then your first path attempt would be correct. 

          1 person found this helpful
          • 2. Re: Path-problem
            Kjoller Level 1

            Thank you....

            Its good to know which attempt should be correct.




            The swf is placed in the root. And the swf is being loaded by my index.php file - and that is obviously also in the root.

            custom_inserts/flashgalleri/ emanates from root


            So my first attempt should be correct... but it doesnt work....


            Let me add a little to this curious problem:


            case 1) If I remove /custom_inserts/flashgalleri/ - and just point directly to the file hent_billede.php - and then place both in the root, it works.


            case 2) If I move case 1 down one folder, for instance to /test/ - so that both swf and hent_billede.php resides in /test/ , it DOESNT work ??!!


            WHAT am I missing here?




            • 3. Re: Path-problem
              Kjoller Level 1





              Case 2) DOES work!!


              Im so sorry, to be wasting your time.

              I'll be back, when I know more about what the problem is...

              • 4. Re: Path-problem
                Kjoller Level 1



                Problem located:


                it turns out that if the folder that contains hent_billede.php is CHMOD'ed to 777 - the flash doesnt work??!!

                I need the folder to be CHMOD777 .... what should I do?