1 2 Previous Next 40 Replies Latest reply on Jul 1, 2009 7:48 PM by Mayank (Adobe)

    Cannot Connect to PHP Service

    xyzb

      Hello,

      After the install, which went with out a hitch, I created a project and then proceeded to connect to a data/service. I select PHP, had it generate the sample service class file, was prompted to install Zend and then got an error that it is "Unable to retrieve operations and entities from the file - Reason: There was an error during service introspection."  I then edited the class file with my DB info and thought it would connect. No go. I created a connection string in Dreamweaver to ensure that all was functioning properly and it is, I was able to connect in Dreamweaver. I then copied my connection string into my Flash Builder class file and still no go.

       

      Any help would be appreciated.

      I am going to try the HTTP service for now.

       

      Thanks!

       

      Here is the error message-

      There was an error during service introspection.
      <br /><b>Warning</b>:  domdocument::domdocument() expects parameter 2 to be long, string given in <b>C:\Program Files\xampp\htdocs\ZendFramework\library\Zend\Amf\Adobe\Introspector.php</b> on line <b>71</b><br /><br /><b>Fatal error</b>:  Call to undefined method domdocument::createElement() in <b>C:\Program Files\xampp\htdocs\ZendFramework\library\Zend\Amf\Adobe\Introspector.php</b> on line <b>98</b><br />

        • 1. Re: Cannot Connect to PHP Service
          Mayank (Adobe) Adobe Employee

          Hi,

           

          I followed the steps mentioned above but was unable to repro the issue.

           

          1. Do you have another version of Zend Framework installed by any chance?

          2. Can you send us the output of phpinfo()?

          3. Please attach <workspace_dir>/.metadata/.log file here.

           

          thnx

          -mayank

          • 2. Re: Cannot Connect to PHP Service
            Shikha Kaushik

            Hi,

             

            Could you please provide more information.

             

            Did you get an error at the time of creating the sample PHP or during the import of PHP after updating the file with database and other details?

             

            Thanks,

            Shikha

            • 3. Re: Cannot Connect to PHP Servicesae
              superstylinks

              same problem also on my xampp installation , it worked perfect with REST service in the previous flex 3 release , is it my apache conf or something related on Flash builder

               

               

              this happens when I call my function that connect to mysql do the query and returns the array object

               

               

              Err log from Flash Builder 4:

               

               

              There was an error during service introspection.
              <br /><b>Warning</b>:  require_once(Zend/Loader/Autoloader.php) [<a href='function.require-once'>function.require-once</a>]: failed to open stream: No such file or directory in <b>C:\xampp\htdocs\MYAPP\bin-debug\gateway.php</b> on line <b>23</b><br /><br /><b>Fatal error</b>:  require_once() [<a href='function.require'>function.require</a>]: Failed opening required 'Zend/Loader/Autoloader.php' (include_path='.;C:\xampp\php\pear\;C:/xampp/htdocs/ZendFramework/library') in <b>C:\xampp\htdocs\MYAPP\bin-debug\gateway.php</b> on line <b>23</b><br />

               

               

              thanks in advance

               

               

              P

              • 4. Re: Cannot Connect to PHP Servicesae
                Shikha Kaushik Level 1

                Hi,

                 

                Incase of XAMPP there's an option to select PHP Version.

                Please can you let me know if you are using PHP 4 or PHP 5.2.6.

                Incase you are using default PHP4 this error would show up as we support PHP 5 or above.

                So please activate PHP Version 5.2.6 and try again and let me know if the issue persists.

                 

                Thanks,

                Shikha

                • 5. Re: Cannot Connect to PHP Servicesae
                  superstylinks Level 1

                  my php version is 5.2.9 , I already restarted the server just incase Znd framwork need it , but same problem ... are you sure I dont need to tweak apache ?

                  • 6. Re: Cannot Connect to PHP Servicesae
                    Shikha Kaushik Level 1

                    can you please provide me one more info.

                    Do you have any prior installation of Zend in webroot of your PHP Server i.e. besides Zend Framework folder is there any other folder Zend present under the webroot.

                    Also, can you once please manually check if under Loader, AutoLoader.php is present or not.

                     

                    Thanks,

                    Shikha

                    • 7. Re: Cannot Connect to PHP Servicesae
                      superstylinks Level 1

                      ok these are all checks:

                       

                      first time installing ZendFramework folder, it was installed by FB while creating the call to my php service there are NOT any other duplicate ZF installation

                       

                      under ---> ZendFramework\library\Zend\Loader --> there's Autoloader.php as default install requires

                       

                      thanks

                       

                       

                      P

                      • 8. Re: Cannot Connect to PHP Service
                        AcidGuy

                        also into this problem,

                        generated sample code, error,

                        created own classes, the same error user described,

                         

                        using xampp, php version 5.2.6.

                        • 9. Re: Cannot Connect to PHP Service
                          superstylinks Level 1

                          I did the same test in the same time .. :-)

                           

                          letting FB 4 create "Generate sample php class" and it generates .. same problem as described before

                           

                          I guess its like FB 4  project settings cannot read the exact path of ZF or maybe we need some workaround to let FB project work on every lamp installation , anyway the other weeks  I was able to use flex 3 with php  rest service without any tweak to my configuration

                          • 10. Re: Cannot Connect to PHP Service
                            xyzb Level 1

                            Could you please confirm if these are the correct default settings for the amf_config.ini?

                             

                            [zend]
                            ;set the zend installation directory
                            ;zend_path = c:\Frameworks\ZendFramework\library

                             

                            [zendamf]
                            amf.production = false
                            amf.directories[] = services

                            • 11. Re: Cannot Connect to PHP Service
                              Shikha Kaushik Level 1

                              As we are unable to reproduce the issue at our end could you please just doubly ensure that the following steps have been done:

                               

                              After starting the XAMPP Server,

                              1. in XAMPP Control Panel switch to PHP Version

                              2. Check the Active PHP Version

                              3. Incase Active PHP Version shows as PHP 4

                              4. click on Activate PHP 5.2.6

                              5. switch to XAMPP tab

                              6.click on Start option for All Components.

                               

                              And then try again creating a sample PHP in a new flex project.

                               

                              Also it would be of really great help if you could attach your output of phpinfo as it would help us in investigating the issue.

                               

                              Any additionaly screenshots or server settings info would be very helpful.

                               

                              So sorry for the inconvenience.

                               

                              Thanks,

                              Shikha

                              • 12. Re: Cannot Connect to PHP Service
                                xyzb Level 1

                                I sent them via email yesterday. It indicated in my email from this forum that it was recommended that I do so. Apparently that is not workng?

                                Here are the files. I am running PHP 5.2.6 by the way.

                                 

                                Thanks

                                • 13. Re: Cannot Connect to PHP Service
                                  Shikha Kaushik Level 1

                                  that's true they are correct default settings of amf_config.ini.

                                  • 14. Re: Cannot Connect to PHP Service
                                    superstylinks Level 1

                                    I tried to recreate the project after delete all the the previous one , but same situation Im now almost sure the bug (incompatibility) is connected to ZF installed by FB 4 and *maybe* ZEND server settings I also recreated the same thing on a different lamp installation , hope you guys at Adobe can manages a  fix,  the web service part of the new FB 4 its very cool as seen on videos on your dev connetion !!

                                     

                                     

                                    Thanks

                                     

                                    P

                                    • 15. Re: Cannot Connect to PHP Service
                                      Mayank (Adobe) Adobe Employee

                                      Hi,

                                       

                                      Thank you for sending out the phpinfo() output. After a look at the error and the phpinfo() output, I tried enabling the php_domxml.dll extension in my php installation. I was able to reproduce the issue with this extension enabled.

                                       

                                      Please log a bug with the phpinfo() output and log file for us to track this issue.

                                       

                                      Just to confirm this, can you try commenting out the php_domxml.dll extension in your php.ini, restarting your server and then retrying the workflow.

                                       

                                      If the problem gets resolved, I guess we would have the culprit.

                                       

                                      -mayank

                                      • 16. Re: Cannot Connect to PHP Service
                                        AcidGuy Level 1

                                        after that modification was made. it works!

                                        well, this is in beta and this is the goal i guess, tracking anomalies,

                                         

                                        would love to see you guys work on this for the commercial ide. thx.

                                        • 17. Re: Cannot Connect to PHP Service
                                          xyzb Level 1

                                          All I can say is YOU ROCK!

                                           

                                          It works now- thanks!

                                           

                                          I will put in a bug report.

                                          • 18. Re: Cannot Connect to PHP Service
                                            superstylinks Level 1

                                            unfortunally still not working on my server

                                             

                                             

                                            There was an error during service introspection.
                                            <br /><b>Warning</b>:  require_once(Zend/Loader/Autoloader.php) [<a href='function.require-once'>function.require-once</a>]: failed to open stream: No such file or directory in <b>C:\www\MYAPP\bin-debug\gateway.php</b> on line <b>23</b><br /><br /><b>Fatal error</b>:  require_once() [<a href='function.require'>function.require</a>]: Failed opening required 'Zend/Loader/Autoloader.php' (include_path='.;C:\\\php\includes;C:/EasyPHP 3.0/www/ZendFramework/library') in <b>C:\www\MYAPP\bin-debug\gateway.php</b> on line <b>23</b><br />

                                             

                                             

                                            on my php.inithe extension was already NOT active

                                             

                                            ;extension=php_domxml.dll

                                             

                                             

                                            can you tell me if there any need for a particular php extension to BE active as default ?

                                            • 19. Re: Cannot Connect to PHP Service
                                              Shikha Kaushik Level 1

                                              Hi,

                                               

                                              I tried with EasyPHP 3.0.

                                              Unfortunately i couldn't reproduce the issue.

                                              It would be really great if you could attach your builder log file and output of phpinfo as this would really help us in figuring out the root cause of the issue.

                                               

                                              So sorry for the inconvenience!

                                               

                                              Thanks,

                                              Shikha

                                              • 20. Re: Cannot Connect to PHP Service
                                                superstylinks Level 1

                                                there's also another little problem that happen sometimes (30% of times ) when I fire up   FB 4  after the popup screens appear it close after 3 seconds without the app starts ... maybe I should try another build of FB  I downloaded this one on Wednesday morning Italian time , did you already published a new build?

                                                 

                                                about the log which is the right path for it , I was looking under my project folder  but I didn't find any log file

                                                 

                                                thanks in advance

                                                • 21. Re: Cannot Connect to PHP Service
                                                  Shikha Kaushik Level 1

                                                  Hi,

                                                   

                                                  For the path to log file please follow either of the steps:

                                                   

                                                  STEP 1

                                                  1. go to Help Menu

                                                  2. click on Product Details

                                                  3. click on Configuration Details

                                                  4. click on View Error Log

                                                  Please copy and attach this log for us.


                                                  STEP 2

                                                  1. go to workspace of the Flash Builder 4

                                                  2. open the folder .metadata

                                                  3. open the .log file

                                                  Please copy and attach this log for us.

                                                   

                                                  As far as phpinfo is concerned,

                                                  http://localhost/home/phpinfo.php

                                                   

                                                  Please let me know if you need any information.

                                                   

                                                  Thanks,

                                                  Shikha

                                                  • 22. Re: Cannot Connect to PHP Service
                                                    superstylinks Level 1

                                                    here the log files , I did a clean new project and cleaned the previous project versions , let me know if you need more info about my php/apache configuration anyway i added my phpinfo

                                                     

                                                     

                                                    thanks

                                                    • 23. Re: Cannot Connect to PHP Service
                                                      Mayank (Adobe) Adobe Employee

                                                      1. You may have tried this before, but can you try installing EasyPHP without a space in the installation folder?

                                                      2. do you have two easyphp's installed? If yes, does C:\EASYPH~1.0\\php\includes contain any older version of ZF?

                                                       

                                                      -mayank

                                                      • 24. Re: Cannot Connect to PHP Service
                                                        xyzb Level 1

                                                        Okay- I spoke too soon :-)  This did help me connect to my DB, but then FB became unstable- it would open and close when I would try to run the program. So this a.m. I removed XAMPP and FB and did a clean install for both.  I ran FB and created a PHP service flawlessly. It even opened the generic class file in Dreamweaver so I could edit it with my DB info.  I created the connection, went back to FB - no errors displayed in any of the panels, switched to Design view to drag a data grid out and FB closed out completely.  I then opened it again, clicked on my project mxml file in the src directory, clicked on Design and it stayed opened.  I then tried to drag a data grid component out on the workspace and it closed again.  So that is where I am right now -

                                                         

                                                        Any ideas?

                                                         

                                                        Thanks

                                                         

                                                        Update-

                                                        I've got it working now and it is displaying my data in the data grid- but it is still unstable(progam closing for no apparent reason). I did check the the php.ini file on my fresh install and the php_domxml.dll is commented out.

                                                         

                                                        jb

                                                        • 25. Re: Cannot Connect to PHP Service
                                                          Mayank (Adobe) Adobe Employee

                                                          I hope you did not delete the logs after this FB crash? If not, then please attach the logs once again over here.

                                                           

                                                          -mayank

                                                          x39901

                                                          • 26. Re: Cannot Connect to PHP Service
                                                            xyzb Level 1

                                                            Here you go-

                                                            • 27. Re: Cannot Connect to PHP Service
                                                              Mayank (Adobe) Adobe Employee

                                                              The logs are getting queued for virus scan, can you mail the log to me -> mayankk (at) adobe (dot) com

                                                              • 28. Re: Cannot Connect to PHP Service
                                                                Mayank (Adobe) Adobe Employee

                                                                The log file seems to be queued ... can you send that log to me by mail -   mayankk adobe com

                                                                 

                                                                -mayank

                                                                • 29. Re: Cannot Connect to PHP Service
                                                                  superstylinks Level 1

                                                                  Im trying now on an a different server ubuntu and oracle, may we have some information about the configuration server Tom Lane from Adobe is using on his demo maybe could help us  to repruduce correctly the PHP services integration on FB4

                                                                   

                                                                  thanks alot

                                                                   

                                                                   

                                                                  P

                                                                  • 30. Re: Cannot Connect to PHP Service
                                                                    Shikha Kaushik Level 1

                                                                    Hi,

                                                                     

                                                                    If you are using Win XP -

                                                                    please try setting up WAMP.

                                                                     

                                                                    for MAC-

                                                                    you can use MAMP Server.

                                                                     

                                                                     

                                                                    Please let me know if you need any information.

                                                                     

                                                                    Thanks,

                                                                    Shikha

                                                                    • 31. Re: Cannot Connect to PHP Service
                                                                      superstylinks Level 1

                                                                      perfetto!!! I'll give it a try now and post the result late this morning, Im too curious now to make it work this php service feature  :-)

                                                                      • 32. Re: Cannot Connect to PHP Service
                                                                        wess36

                                                                        Hi,

                                                                         

                                                                        I got a problem too on this stuff.

                                                                         

                                                                        I can create the service but when i drag the service on a datagrid, after the 'create new data type' dialog i got a error, see my screen shot for more infos.

                                                                        As it's in french, i try too translate it for you, it's says that 'an error append while calling operation.The server did not send back anything.Try too see in server's log for more details.'

                                                                        I joint screenShot.

                                                                        I'm on vista, using wamp 2.0H running PHP 5.2.9-2

                                                                         

                                                                        Thanks for any help you could give me

                                                                        • 33. Re: Cannot Connect to PHP Service
                                                                          superstylinks Level 1

                                                                          ciao Shikha,

                                                                           

                                                                          no way also with WAMP same error as  posted before  when trying the other lamp installers on windows

                                                                           

                                                                           

                                                                          There was an error during service introspection.
                                                                          <br /><b>Warning</b>:  require_once(Zend/Loader/Autoloader.php) [<a href='function.require-once'>function.require-once</a>]: failed to open stream: No such file or directory in <b>C:\wamp\www\1\MYAPP-debug\gateway.php</b> on line <b>23</b><br /><br /><b>Fatal error</b>:  require_once() [<a href='function.require'>function.require</a>]: Failed opening required 'Zend/Loader/Autoloader.php' (include_path='.;C:\php5\pear;C:/wamp/www//ZendFramework/library') in <b>C:\wamp\www\1\MYAPP-debug\gateway.php</b> on line <b>23</b><br />

                                                                           

                                                                          someone who was able to do at list the connection with service could post gateway.php just to see if its the same as the one writen by FB4 on my root

                                                                          • 34. Re: Cannot Connect to PHP Service
                                                                            dnprossi

                                                                            I have same problem on wamp 2.0 when I created a project in a c:\wamp\www\sub-folder\projectname-debug.

                                                                             

                                                                            Flash Builder installs Zend Framework in c:\wamp\www\sub-folder and not in c:\wamp\www webroot folder.

                                                                             

                                                                            I moved ZendFramework folder to webroot folder pressed Ok button on "error window" and FINISH again on "Configure PHP service window" and all went well.

                                                                             

                                                                            I then created a new project exactly the same as above with different name and tried again, Flash Builder does not find ZendFramework in webroot folder and requests Zend install again.

                                                                             

                                                                            Creating projects in webroot normally without subfolder does not give any problem.

                                                                             

                                                                            Flash Builder should see in webroot only and not control subfolders...

                                                                             

                                                                            Hope this is clear and can help.

                                                                            • 35. Re: Cannot Connect to PHP Service
                                                                              wess36 Level 1

                                                                              Thanks for your answer dnprossi !

                                                                               

                                                                              I've also experienced the same troubles you are describing, but my problem is later. When i try too drag and drop the function listed in the data/service area to a datagrid on the stage, (You can see the screen shoot i've send in my previous post for more infos) i just got a error message but what this message says do not give me any help too find where the error come from.

                                                                              • 36. Re: Cannot Connect to PHP Service
                                                                                Shikha Kaushik Level 1

                                                                                Hi,

                                                                                 

                                                                                Can you please provide me your php file so that we can look into the issue.

                                                                                 

                                                                                In case you are using database please provide me your dump file too.

                                                                                 

                                                                                Please mail your php file and dump file at shikaush@adobe.com

                                                                                 

                                                                                Thanks,

                                                                                Shikha

                                                                                • 37. Re: Cannot Connect to PHP Service
                                                                                  Mayank (Adobe) Adobe Employee

                                                                                  The original query of this thread has been answered, starting a new thread for this query:

                                                                                  http://forums.adobe.com/thread/444324

                                                                                   

                                                                                  Please use the other thread for further discussion.

                                                                                   

                                                                                  -mayank

                                                                                  • 38. Re: Cannot Connect to PHP Service
                                                                                    mxmotion

                                                                                    I've got the same error but mac version... help... please!!!

                                                                                    • 39. Re: Cannot Connect to PHP Service
                                                                                      mxmotion Level 1

                                                                                      Obviously there are any .dll extensions by the way

                                                                                      1 2 Previous Next