Experimental project

This is a sandbox project, which contains experimental code for developer use only.

Slipscript is a module you'll love to hate. (Or hate to love?) It allows for the execution of arbitrary PHP scripts at URL's defined through the administrative interface. It is probably not dangerous but for now it will install into your system in a module group called "POTENTIALLY DANGEROUS CODE" just to be safe while the community weighs in on this idea.

Slipscript respects Drupal's MVC-like organization to the best it can, including the Twig templating/rendering and the Drupal routing system. But in-between these layers it allows you to run plain-old PHP code, including rendering output manually to display on the page.

An example might be a custom product page, where a simple PHP script might check a user's discount level and modify the price accordingly. You can also feed arguments and Slipscript will hand them to you as standard variables like $arg1, $arg2, $arg3 etc.

To use this module:

1. Install as normally,
2. Go to Structure -> Slipscripts and enter a "verb" such as "products" (and clear cache)
3. Create a folder called "_slipscripts" in your site root, and a folder in that with the same name (the "verb")
4. Put your PHP script in that subfolder with the same "verb" name and an ".inc" extension (NOT PHP).
5. Go to http://example.com/verb/arg1/blah/whatever and see the result of your script!

Project information