Debugging with Local Webserver, Setting up Symfony2 Project

First, congrats on releasing PhpStorm5.  I've been waiting for it to actually switch to using PhpStorm, and am not commited to learning it.

But I'm stuck the same place I got stuck before -- when creating a new project, I select "Local Web Server" and "Local Sources" (first option) but get stuck on the simple questions.  First question: "Choose a Directory to create the project in".  Is that the directory where my source files exist?  Or is this for phpStorm-related files.

The core issue is probably the Add Local Server, and the url to the configuration root.

Maybe it'd be easier if I just explained the Symfony Standard setup.  Let's say I have a domain, and I have pointing to  I've downloaded the source files into


From the symfony sample project at

The web root is at


The main controller file is app_dev.php, so to launch my app, I want to go to

My webserver is local, my files are local.

So what URL do I use when setting up the new local server.  The prompt says "Browse Files on Server" and then Web Server Root Url.  I tried

but that didn't work.

Then it ask for the web path for the project root.  I'm confused, because my web files are in /web, but my DOCUMENT_ROOT is set to /var/www/symfony-standard/web

Sorry, I'm sure these are simple questions.  Is there a video you can point me to that I can walk through?

Thanks, and again, congrats.  I'm very excited about the new Symfony2 support.


1 comment
Comment actions Permalink

Hi there,

Instead of going trough the wizard, I would suggest just use "File | Open Directory" and configure the rest manually when required (less confusing).

I'm not using Symfony2, but have somehow similar setup, when webroot is not root of the project but just a subfolder. The idea is:

  • Project root: /var/www/symfony-standard
  • In Project View panel -- mark /var/www/symfony-standard/web as Resource Root (for validating links to images/js and similar resources)
  • In "Settings | Deployment" create the desired entry -- "In Place" is what you need when files are already in place.
      • On Connection tab -- URL =
      • On Mappings tab:
        • Local path -- /var/www/symfony-standard/web should be fine (If deployment entry would be of any other type (e.g. (S)FTP(S)/Shared) then the value should be /var/www/symfony-standard (yep -- project root) otherwise you will not be able to transfer/upload any files outside of the website root. This also means that "Open in browser" or similar actions will not work correctly -- but you don't really need them. Unfortunately PhpStorm has no ability to specify what folder is actually a website root -- )
        • Web path: just /
    • You can now create Run configuration to launch your app from within PhpStorm:
      • "Run | Edit Configurations..."
      • Choose "PHP Web Application" type -- the rest is self explanatory
      • When done -- choose it in drop down box on main toolbar -- now you can launch it using "Run" button.

    Please sign in to leave a comment.