NuSphere Forums Forum Index
NuSphere Forums
Reply to topic
debugger settings with symfony


Joined: 23 Nov 2007
Posts: 11
Reply with quote
Hi All,

need help getting the debugger set when using Symfony
(I did not want to post a dir structure for symfony since it is already posted in another post).

Here is my setup:

- I am using a linux machine loaded with apache, symfony etc.

the document root is:

/home/user1/sandbox/myproject/web/

the path to website files is:

/home/user1/sandbox/myproject/web/

DBG (PHP DEBUGGER) Version 3.2.10 is INSTALLED

Other settings are under Project Publishing:

Account: foo
Top publishing directory: myproject

Now under Accounts in PhPED: the "foo" account
Root directory: /home/user1/sandbox

Now, the main difference between other people posting similar questions re Symfony is that I am using phped on a Windows machine while my server is a Linux machine on the network, so the web server and its files are not local to where PhPED resides.

I've created a local directory

C:/Desktop/myproject and by creating the ssh account "foo" in phped, I am moving files back and forth as I edit them. This worked fine since I was not using the debugger. Now, I want to use the debugger and so I run the dbg-wizard.php

Now, the dbg-wizard.php is located on the linux machine in the

/home/user1/sandbox/myproject/web/dbg-wizard.php

It suggested the following settings:

Project -> Root Directory:
Select the location where you will store the copies of the files from /home/user1/sandbox/myproject/web/ from your server myproject.
Note: if you are using Samba or some other file sharing system, you can simply point Root Directory to /home/user1/sandbox/myproject/web/ instead of copying it

Mapping -> Run Mode: HTTP Mode (3-rd party WEB server)
Mapping -> Remote URL: http://myproject/
Mapping -> Remote Root Directory: /home/user1/sandbox/myproject/web/


So, if I use the above setting in PhpEd (local on the windows machine) I cannot "see" any of the files that use to be under C:\Desktop\myproject, but only the ones that are under
C:\Desktop\myproject\web

so, anytime I try to start the debugger on the index.php file it runs until it need another file and I am getting the message:
Failed to map "/home/user1/sandbox/directory/file" remote file to publishing account.

Which I tend to believe Smile since that directory is not visible in the PhPED workspace for myproject because of the Project-> Root Directory that points to:
C:\Desktop\myproject\web

Now, if I try to change the Project -> Root Directory to point to
C:\Desktop\myproject (so that all the files show up noe in PhpED)

again when running the debugger on the index.php file the message is now:

Failed to start debug session.

Page http://myproject/web/index.php not found on the web server, make sure the ....

Well, of course it cannot find it because it is not suppose to access it that way. Remember the document root is already set to
/home/user1/sandbox/myproject/web/ - which dbg-wizard figured out correctly, so now all the debugger needs to access it would be

http://myproject/index.php

Please help Crying or Very sad

Thanks, Olimpiu
View user's profileFind all posts by odejeuSend private message
Site Admin

Joined: 13 Jul 2003
Posts: 8344
Reply with quote
Quote:
So, if I use the above setting in PhpEd (local on the windows machine) I cannot "see" any of the files that use to be under C:\Desktop\myproject, but only the ones that are under C:\Desktop\myproject\web

seems you set this directory as a project root while it should be C:/Desktop/myproject
If your web root corresponds to C:/Desktop/myproject/web, just leave project's URL EMPTY, set /home/user1/sandbox/myproject/ as remote root and add one mapping entry on the mapping tab:
local root: C:\Desktop\myproject\web
url: http://blahblahblah/ (should be root URL of your web site, without any filenames)
remote root: /home/user1/sandbox/myproject/web

btw, why don't you use linux Samba? in this case you'd share /home/user1/sandbox/myproject/, map it on your windows box as a network drive and work with remote files directly.

_________________
The PHP IDE team
View user's profileFind all posts by dmitriSend private messageVisit poster's website


Joined: 23 Nov 2007
Posts: 11
Reply with quote
Thanks for the suggestion Dmitri! Got it to work with Samba. Much better now Smile

Thanks again,
Olimpiu
View user's profileFind all posts by odejeuSend private message


Joined: 17 Nov 2008
Posts: 3
Location: Rohnert Park, CA
Reply with quote
I am having a similar issue.

DBG Wizard server info output:

* PHP Version: 5.2.4-2ubuntu5.3
* Web Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.3 with Suhosin-Patch
* Server Name: mywebserver
* Platform: Linux glibc-2.7/x86
* Your Client IP Address: 192.168.1.11
* Your Server IP Address: 192.168.1.21
* Port: 80
* Your Web Server and PhpED are on different machines
* Path to website files: /media/projects/JLCoady/Implementation/site/web/
* Document Root is: /media/projects/JLCoady/Implementation/site/web/
* Your PHP.INI file is: /etc/php5/apache2/php.ini
* PHP extensions directory is: /usr/lib/php5/20060613+lfs
* DBG (PHP DEBUGGER) Version 3.4.2 is INSTALLED

And project settings suggestions:

* Project -> Root Directory: /media/projects/JLCoady/Implementation/site/web/
* Mapping -> Run Mode: HTTP Mode (3-rd party WEB server)
* Mapping -> Remote URL: http://mywebserver/
* Mapping -> Remote Root Directory: /media/projects/JLCoady/Implementation/site/web/

I am using samba and /media/projects/JLCoady/Implementation maps to E:\Projects\JLCoady\Implementation on my dev machine where PhpED is installed and I have set E:\Projects\JLCoady\Implementation as the project root. The problem is that PhpED requires a remote URL ... it wont let me leave it blank

I tried creating a new mapping with

local root: E:\Projects\JLCoady\Implementation\site\web
url: http://mywebserver/
remote root: /media/projects/JLCoady/Implementation/site/web/

but after i hit OK the open the project properties again this mapping is no longer there..

Any ideas?

_________________
JC
View user's profileFind all posts by joshcoadySend private messageYahoo Messenger


Joined: 17 Nov 2008
Posts: 3
Location: Rohnert Park, CA
Reply with quote
I got this figured out ... I needed to leave BOTH mapping-> remote url and mapping->remote root dir blank

Also, I ended up needing to create a samba share of /usr/share/php/ so it would be accessible to the debugger.

_________________
JC
View user's profileFind all posts by joshcoadySend private messageYahoo Messenger
debugger settings with symfony
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
All times are GMT - 5 Hours  
Page 1 of 1  

  
  
 Reply to topic