This Question is Answered

1 "helpful" answer available (2 pts)
4 Replies Last post: Oct 5, 2013 5:28 PM by Greg Gum  
Greg Gum Newbie 5 posts since
Oct 5, 2013
Currently Being Moderated

Oct 5, 2013 7:19 AM

How to View index.php in Browser

Hi, I am new to PHP Storm and am trying to get started with it.I create a new blank project, then add a php file called index.php.I then add one line of code echo phpinfo();.How do I prevew this in a browser?  The help file says to press alt F2, but this gives me the bookmark window.  I don't see the hover window that is supposed to be available.  I have set the browser in Settings/IDE/Browser.Is there something else I am supposed to do?Greg
Andriy Bazanov Master 3,898 posts since
May 28, 2010
Currently Being Moderated
Oct 5, 2013 2:30 PM in response to: Greg Gum
Re: How to View index.php in Browser

Hi there,

 

Yes, it is Alt+F2 for preview functionality.

 

The help file says to press alt F2, but this gives me the bookmark window.

Seems you are using different keymap (Settings | Keymap).

 

Please check (and use) whataver shortcut you have assigned to "View | Prevew file in..."  (focus must be in Editor window (and not side tool windows) when menu is invoked).

Andriy Bazanov Master 3,898 posts since
May 28, 2010
Currently Being Moderated
Oct 5, 2013 4:02 PM in response to: Greg Gum
Re: How to View index.php in Browser

What version do you use?

 

As I understand it is 6.0.3.  If so :

  1. Try restarting IDE
  2. Create some html file -- see if this action will be available for that file (from what I see it's not always available for php files)

 

In any case: if you properly define Deployment entry ("In Place" type should be OK) and mark it as Default; then you will be able to use "View | Open in Browser..." on any file (default browser will be used)

 

P.S.

Try upcoming v7 (EAP build available now) -- it has been reworked quite a bit in this area so it should work for php files as well

More Like This

  • Retrieving data ...