I've been desperately trying to debug why TaglibHelper XSP taglibs need
you to define the parse_start, parse_end and parse_chars subs. And I can't
for the life of me figure it out.
The following TLH module works:
package AxKit::XSP::TLHDemo;
use strict;
use Apache::AxKit::Language::XSP::TaglibHelper;
use Time::Piece;
use vars qw(@ISA $NS $VERSION @EXPORT_TAGLIB);
BEGIN {
@ISA = qw(Apache::AxKit::Language::XSP::TaglibHelper);
$NS = 'http://axkit.org/xsp/demo/datetime';
$VERSION = '0.01';
@EXPORT_TAGLIB = ('now()');
}
sub parse_start { shift->SUPER::parse_start(@_); }
sub parse_end { shift->SUPER::parse_end(@_); }
sub parse_chars { shift->SUPER::parse_chars(@_); }
sub now () {
return localtime->strftime("%I:%M%P on %A %e %B, %Y");
}
1;
__END__
But, if I comment out the sub parse_* functions, it fails to work, even
though the functions themselves simply call their SUPER method of the same
name!!!
I really don't understand what could cause this to happen. If I call the
module from the command line, I can check
AxKit::XSP::TLHDemo->can("parse_start"), and it returns a valid subref. So
this is something to do with mod_perl. Yet other modules that are loaded
the same way work perfectly well with @ISA.
Help. I'm boggled.
--
<!-- Matt -->
<:->Get a smart net</:->
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]