How to start php project from sublime text 2

Is there a way to configure sublime text 2 to build (or run) the php script I am editing?

+8
php sublimetext2
source share
2 answers

You can do Tools -> Build System -> New Build System... and then edit the file as follows:

 { "cmd": ["/path/to/some/script/that/runs/your/project"] } 

Then save it and from your project select Tools -> Build System -> <your new name>

Now you can press control-shift-b to run the script.

+2
source share

If you are a Linux or Mac user, you can do this.

Tools → Build System → New Build System

 { "cmd": ["php" , "$file"] } 

It will run your php codes on an elevated text console

here is a screenshot if you are wondering what it looks like.

enter image description here

+27
source share

All Articles