1 sam2kb Apr 25, 2009 20:46
3 yabba Apr 28, 2009 20:25
no idea off the top of my head.
¥
4 edb Apr 29, 2009 01:23
I'm gonna take a wild guess at this one. Just because I got up late. You want the bit for
'td' => '% {Obj}->my_func( #title# ) %',
right? So how about first playing with Mister Obj to get #title# then do my_func to it. Like, I'm guessing you want to do something with something's title. Perhaps a post title? So get the title then do my_func until finally you have $my_funced_title. Then you can do
'td' => $my_funced_title,
or maybe
'td' => '%'.$my_funced_title.'%',
if the percent thingies are for like a "LIKE" query.
One might think of it as beating the database into submission, but hey if it works and there ain't no laws against it ... ;)
5 sam2kb Apr 29, 2009 07:13
Thank you guys, I already found a workaround
function td_results_my_func( $var )
{
global $Plugins;
$My_Plugin = $Plugins->get_by_code('my_code');
return $My_Plugin->my_func($var);
}
$Results->cols[] = array(
'th' => $this->T_('Title'),
'td' => '% td_results_my_func( #title# ) %',
'order' => 'title',
);
Anyone ?