perl-docs-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stas Bekman <>
Subject Re: [PATCH] Implement <head> elements moving in DocSet
Date Wed, 12 Jun 2002 04:08:54 GMT
Per Einar Ellefsen wrote:
> Hi,
> So I decided to try and get that one working. I did :)
> It works ok for 404.html... It might create some problems if somebody 
> inserts meta tags into the source HTML that we're already setting in the 
> resulting HTML (by the way--wouldn't it be better to set the description 
> to the current abstract instead of the same for all pages?), as those 
> would be duplicated.
> I copy the headers verbatim. It's easier that way, because I didn't have 
> to invent complicated datastructures that aren't really necessary anyway.

Easier yes, but it won't work nicely. The <head> must be parsed 
completely and sent to the templates as a hash (array?) with elements of 
the head (excluding title and description), so the templates will be 
able to set the default for those headers that weren't set, but not 
duplicate the existing headers e.g. consider <meta name="keywords" 
content="...">, which can be set in the source html header.

probably something like this:

   headers => {
       meta => [
          'keywords'    => 'the content part',
          'description' => '...'
       base => ...

It's not easy though, since different tags have different elements, so 
the templates should be aware of that.

But if templates never receive raw HTML, later on we can extend POD to 
provide similar headers.

Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker     mod_perl Guide --->

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message