Commit cd8f92b9 authored by Nigel McNie's avatar Nigel McNie Committed by Nigel McNie
Browse files

Standardised how plugin files are included

parent 5fb9139f
...@@ -27,7 +27,6 @@ ...@@ -27,7 +27,6 @@
// @todo this renderer needs to take into account potentially being called more // @todo this renderer needs to take into account potentially being called more
// than once in the same PHP script (clobbering of the $formrenderermct variable). // than once in the same PHP script (clobbering of the $formrenderermct variable).
// Also, not sure what 'static $var' does in global scope... // Also, not sure what 'static $var' does in global scope...
require_once(dirname(__FILE__) . '/table.php');
static $formrenderermct; static $formrenderermct;
/** /**
...@@ -43,6 +42,8 @@ static $formrenderermct; ...@@ -43,6 +42,8 @@ static $formrenderermct;
*/ */
function pieform_renderer_multicolumntable(Pieform $form, $builtelement, $rawelement) { function pieform_renderer_multicolumntable(Pieform $form, $builtelement, $rawelement) {
global $formrenderermct; global $formrenderermct;
// Used by the messages javascript function
$form->include_plugin('renderer', 'table');
$formrenderermct->add_element($builtelement, $rawelement); $formrenderermct->add_element($builtelement, $rawelement);
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment