php专区

 首页 > php专区 > PHP高级 > 缓存异常处理 > Sublime Text中运作PHP(转)

Sublime Text中运作PHP(转)

分享到:
【字体:
导读:
         摘要:Sublime Text中运行PHP(转) Sublime Text 2 has the concept of build systems. This basically means that if you are editing a Python file then you can run...

Sublime Text中运作PHP(转)
Sublime Text中运行PHP(转)

Sublime Text 2 has the concept of build systems. This basically means that if you are editing a Python file then you can run the Python interpreter on the source file your are editing and see the output in a console window, all without having to leave the Sublime editor. It’s surprising how much quicker and easier this is compared to having to leave Sublime to swap to a?separate?console window. This is Sublime’s Tools->Build System menuPHP Build Sublime Text 2Surprisingly, there is no supplied build system for PHP, to add one go to “New Build System”. A new tab opens for file?untitled.sublime-build?with the following in it:

{ “cmd”: [“make”] }

Delete that and replace it with this:

{ “cmd”: [“php”, “$file”], “file_regex”: “php$”, “selector”: “source.php” }

And save the file. Sublime will pop up the file save dialog, which defaults to the directory that Sublime uses for its user-generated config files, so don’t change the directory, just save this file as?php.sublime-build. Now, when you edit a file whose name ends with?php?(as specified by the “php$” regex in the config file) you will have a build system available. You can now hit CTRL+B and the PHP?interpreter?will run against your source file and the output appears in a Sublime Text window.Sublime Text build PHPThe grey window shows the output of the PHP interpreter and the time it took to run.

Sublime Text中运作PHP(转)
分享到:
phpcms 丢失密码怎么找回
phpcms 丢失密码怎么找回 phpcms 丢失密码如何找回 phpcms 系统丢失密码如何找回? ? 用户名phpcms 密码 phpcms ? phpcms ? fa3250300be9b7ab0848257f3cbb06e7 ? ucFfAp phpcms 丢失密码怎么找回
PHP本地环境搭配——WAMP不能启动, 一直...
PHP本地环境搭配——WAMP不能启动, 一直处于红色图标的解决方法 PHP本地环境搭配——WAMP不能启动, 一直处于红色图标的解决办法 WAMP不能启动, 一直处于红色图标(正常启动为绿色吧) 考虑是端口的问题,我找到wamp文件夹中的wamp\bin\apache\apache2.2.22\conf路径下的httpd.conf文件,将: #Listen 12.34.56.78:80 Liste...
  •         php迷,一个php技术的分享社区,专属您自己的技术摘抄本、收藏夹。
  • 在这里……