On Thursday 03 October 2002 01:14, [EMAIL PROTECTED] wrote: > Hi, I'm rather new to axkit, and have some perl/xml experience. I've seen > the many examples of using taglibs, including Matt Sargeant's example: > > package AxKit::XSP::DateTime; > use strict; > use Apache::Axkit::Language::XSP::SimpleTaglib; > $VERSION=0.90; > $NS='http://axkit.org/xsp/demo/datetime'; > sub now { > return localtime->strftime("%I:%M%P on %A %e %B, %Y"); > } > package AxKit::XSP::Datetime::Handlers; > sub now: expr { > return 'AxKit::XSP::Datetime::now();'; > } > 1 > > I understand how to layout the index.xsp page and add the processor > directive for xsl2html.xsl transformation, but where should the above code > be placed? Is there a specific file this perl taglib code needs to be in? > Should it be included in the xsl document, if so how? Basically, I'm > getting 500 server errors and in the apache log it says something like > Apache::AxKit::Language::XSP::SimpleTaglib 'cannot find function' or > something similiar to that. Thanks folks.
A taglib is located in your perl search path with the usual naming conventions for perl modules. Thus, your example could be located in /usr/lib/perl5/AxKit/XSP/DateTime.pm (replace '/usr/lib/perl5' with your local perl module path - there are usually 4-8 possible locations). In yout httpd.conf, you then need "AxAddXSPTaglib AxKit::XSP::DateTime". Taglibs are completely unrelated to XSLT, so keep that away until XSP runs. CU J�rg --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
