[Petal] Re: Style Sheet difficulties

garry espe garry.espe at chsinc.com
Fri May 6 15:51:15 BST 2005


Grant McLean <grant at ...> writes:


> 
> It appears that your stylesheet is being interpreted as a Perl script.
> This is definitely not a Petal problem, but possibly an Apache config
> issue.

Yes, I believe this was the problem.
> 
> Are you calling Petal from a CGI script?  If so, the stylesheet probably
> shouldn't be in the CGI directory.  Perhaps you could move it to the
> docroot directory and change you template to include a leading /
> 
>    <at> import url(/style.css);
> 
I am using mod_perl.  I moved the style sheet and other html files to  the doc
root directory, and the problems vanished -- all except one.

> By the way, is there any reason why you're using import rather than a
> <link> tag?:
> 
>   <link rel="stylesheet" type="text/css" href="/style.css" />

I tried this, which produced a PETAL tokenizer error.  PETAL does not bark when
I use the <at> import construct.  Even with the <at> construct, PETAL coughs
when I tryin to reference a style sheet class, like this:
<td CLASS=sidebar> Goodbye </td>  
Here is the error message:
[Fri May  6 09:38:00 2005] [error] [PETAL ERROR] cannot tokenize: <td
CLASS=sidebar> Goodbye  at /usr/lib/perl5/site_perl/5.6.1/MKDoc/XML/Tokenizer.pm
line 89. . Debug info written in /tmp/petal_debug.8605.1115390280.ucwdsnhgwi. at
/usr/lib/perl5/site_perl/5.6.1/Petal.pm line 473.

Any ideas?

Garry

p.s.   Thanks for helping me get untracked.  I was not thinking clearly at all
about the apache config.







More information about the Petal mailing list