On Sun, 24 Nov 2002, Kjetil Kjernsmo wrote: > Hi folks! > > I'm trying to get a minimal SimpleTaglib snippet working, but I'm not > doing to good. I'm on a Debian Woody box, but I have the axkit, > axkit-examples and axkit-xsp-webutils packages from Sarge installed. My > Perl installation is the one from Woody, i.e. 5.6.1. I think the > SimpleTaglib is also from Sarge. I just tried to install it from CPAN, > but that seemed to pull Axkit, and that is perhaps not such a bright > idea right now? > > Well, anyway, that was not really the topic. First, I tried to work on > some DBI-stuff, but after running into trouble, I stripped down as much > as I could, and now this is the Perl code I've got in > /usr/local/lib/site_perl/Kjetils/XSP/Test1.pm: > #! /usr/bin/perl > > package Kjetils::XSP::Test1; > > $NS = "http://www.kjernsmo.net/taglibs/dbi/test1"; > > use Apache::AxKit::Language::XSP::SimpleTaglib; > > > package Kjetils::XSP::Test1::Handlers; > > sub report > { > $data = "data1"; > return $data; > }
SimpleTaglib inserts what you return as perl code into the resulting XSP file. So what you need to insert is not 'data1', it's actually '"data1"' Confused yet? Personally I find TaglibHelper a little easier to use, and if you had used it you would have found that your string would have been inserted as you expected. But it depends what you like. If you grok the fact that taglibs just insert code into your XSP file, then SimpleTaglib is for you. If you don't care about the details of that, then you'll be happier with TaglibHelper. -- <!-- Matt --> <:->Get a smart net</:-> --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
