Structures_DataGrid_Renderer - doesnt' allow custom renderers outside of PEAR directory tree
| From: | Ian P. Christian | Date: | Fri, 28 Jan 2005 15:54:44 +0000 |
| Subject: | Structures_DataGrid_Renderer - doesnt' allow custom renderers outside of PEAR directory tree | ||
| Groups: | php.pear.general | ||
| Request: | Send a blank email to pear-general+get-17236@lists.php.net to get a copy of this message | ||
The following member function of Structures_DataGrid_Renderer resticts you
from generating your own Renderer class and using it.
function setRenderer($renderer)
{
$class = 'Structures_DataGrid_Renderer_' . $renderer;
$file = 'Structures/DataGrid/Renderer/' . $renderer . '.php';
if (@include_once($file)) {
$this->renderer = new $class($this);
} else {
return new PEAR_Error('Invalid renderer');
}
return true;
}
Perhaps I'm missing something, but it should be possible to write your own
renderer and apply it to a datagrid?
I'm trying to make it so that the first line in the table is a form used to
filter, and without putting my render file in the PEAR directory (or setting
the include path and creating a matching structure) I cannot do so.
ideas?
Kind Regards,
--
Ian P. Christian
http://pookey.co.uk