Is there a PHP Sandbox, something like JSFiddle is to JS?

PhpSandbox

Php Problem Overview


Is there a PHP Sandbox, something like JSFiddle is to JS?

Php Solutions


Solution 1 - Php

If you are just looking for an online site to play around with PHP code, try

The most sophisticated is:

It lets you test your code in all PHP versions starting from PHP4.

If you want something for your local environment, the Runkit extension aims to provide a PHP Sandbox:

> Instantiating the Runkit_Sandbox class creates a new thread with its own scope and program stack. Using a set of options passed to the constructor, this environment may be restricted to a subset of what the primary interpreter can do and provide a safer environment for executing user supplied code.

If you dont want to use Runkit but still want a PHP Console on your server, try

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
QuestionJiew MengView Question on Stackoverflow
Solution 1 - PhpGordonView Answer on Stackoverflow