Execute Snippet As PHP

komodo ide blog hero

Macro Monday – a new macro to dig into every Monday!

Often you might be editing a PHP script and you want to quickly execute a snippet
of code to test it on its own, or you might even want to simply use PHP to quickly
perform some logic for you on the fly. It’s with that in mind that I originally
created this macro years ago. You simply write some code, select your code and
execute the macro to run your code and see the results. If you have no code
selected then the current file is used. The best part for me is that the file
does not need to be saved, allowing for quick testing.
This macro could easily be modified to support multiple languages, please feel
free to fork it and submit your modifications.


To install the macro simply hit the “View Resource” and “Install Instructions”
links below. You’ll want to hook the macro up to the “On Startup” trigger.

Share Your Own Awesome Macros

Do you have your own awesome macro’s that you think others could benefit from?
Submit them to the Resources Section and if you really want to get it noticed
write a Macro Monday blog about it.

Recent Posts

Scroll to Top