#### How do I do stuff? Just do it. Stuff is best done by doing it. By not doing it, stuff doesn't happen. What do I do with this stuff? Stuff. You do stuff with stuff. That way the stuff is used. Do I really have to do stuff? Of course not, you can just sit there without doing anything. Well you do have to breathe and eat and use Data::Dumper here and there. Stuff is good. Don't be afraid of stuff. My girlfriend says stuff. Should we break up? Of course not. It is common for a spouse to say stuff, you should encourage them and stuff. #### use strict; use HTML::Template; use XML::Simple; my $xml = XMLin('./faq.xml') or die $!; my $template = HTML::Template->new( filename => 'faq.tmpl', die_on_bad_params => 0, ); # this could definitely use some refactoring - oh well ;) foreach my $cat (@{$xml->{'category'}}) { $cat->{'anchor'} = $cat->{'type'}; $cat->{'anchor'} =~ s/ /_/g; $cat->{'anchor'} =~ s/[^\w]//g; } $template->param( category => $xml->{'category'}, ); print $template->output();