SproutCMS

This is the code documentation for the SproutCMS project

Page options:

Inherited members

class Preview

Somewhat complicated preview system which copies existing data into
temporary tables, then renders the preview via a front-end method call

Functions

NameVisibilityDescription
loadpublic (static)Loads a preview by creating temporary tables in SQL, calling a
runpublic (static)Run a controller method using the preview data.

public load

int Preview::load ( ManagedAdminController $ctlr , array $tables [, int $record_id ] );

Loads a preview by creating temporary tables in SQL, calling a
controller's _editSave method, and then calling a method it would
normally use to display its (non-temporary) data

public run

void Preview::run ( Controller $ctlr , string $method , array $args );

Run a controller method using the preview data.
This injects the word 'PREVIEW' into the page title