Dript is a scripting engine running around Drupal. Dript can be used by other modules to add scripting or formula capability. The module itself implements a filter that can be applied to nodes and other contents. Dript is simpler and safer than PHP. It is meant to be a glue language similar to formula in spreadsheet with the casual programming concept "once coded it will be forgotten". As a dialect of LISP and a simpler LISP, Dript is for non-programmers who want to alter their contents slightly according to certain behaviors. Dript will give ordinary users or administrators a capability to add function and logic on the fly while working with Drupal without having to go down with PHP or creating a module.
Here is a snapshot of Dript. Let's assume a node has CCK fields 'Quantity' and 'Unit Price'. The following will show the total price in the content:
Total price is [driptne
(* (drupal-read-field 'this "Quantity")(drupal-read-field 'this "Unit Price"))
Alternatively you may paste the same code as a value inside another CCK field 'Total' which will make 'Total' a calculated field.
Contributors are welcome to add more Drupal functions to Dript. All primary LISP functions have been implemented such as car, cdr, cons, list, quote, apply, lambda, cond, if, while, for, foreach, etc. Dript is implemented 100% using PHP which means nothing else is to be installed onto the host. Each Dript function is kept in a separate file that only in-used functions will be loaded. Thus adding more function to Dript will not affect performance.
Dript is an on-going project. More functions will be added from time to time. Currently there are more than 80 functions implemented.