On Fri, May 16, 2008 at 12:40 PM, I wrote: > I'm trying to convert the AxKit::XSP::WebUtils taglib to AxKit2, > partly because it is used by several of my web apps, partly because > it's a good exercise in AxKit2. However, to do this I need my taglib > functions to have access to the current client object. Like Matt and > Lars were discussing here: > http://www.mail-archive.com/axkit-users@axkit.org/msg06049.html > but I am a bit at a loss how to use the 'nasty global hack'. Any ideas?
I've managed to find a rather nasty hack to solve this problem. In lib/AxKit2/XSP/TaglibHelper.pm I've changed line 436 from . func_name($funspec) . "("; to . func_name($funspec) . "(\$self->client,"; which makes every taglib function be called with an extra (mandatory, first) argument which contains the client object. It works --at least it does for my own version of AxKit::XSP::WebUtils--, but of course the hack is pretty nasty, if only because I have to change all taglib functions. I will really try to find a neater solution, but thought I'd share this for the time being. Martijn. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]