Looks fine. Can someone else check it in? Being monitor-less makes doing
AxKit things extremely difficult.

On Thu, 11 Jul 2002, Christopher H. Laco wrote:

> Here they are.
> Be gentle.  :-)
>
> I tried updating the pod as well, but double check it/hack it as necessary.
>
> -=Chris
>
>
> ---START QUERYSTRING DIFF---
> --- QueryString.pm.orig Thu Jul 11 11:12:19 2002
> +++ QueryString.pm      Thu Jul 11 12:16:39 2002
> @@ -9,8 +9,10 @@
>       my $r = shift;
>
>       my %in = $r->args();
> -     if ($in{style}) {
> -       $r->notes('preferred_style', $in{style});
> +     my $key = $r->dir_config('AxStyleChooserQueryStringKey') || 'style';
> +
> +     if ($in{$key}) {
> +       $r->notes('preferred_style', $in{$key});
>       }
>       return OK;
>  }
> @@ -36,9 +38,21 @@
>       PerlHandler Apache::AxKit::StyleChooser::QueryString \
>                 AxKit
>
> +By default, the key name of the name/value pair is 'style'.
> +This can be changed by setting the variable AxStyleChooserQueryStringKey
> +in your httpd.conf:
> +
> +     PerlSetVar AxStyleChooserQueryStringKey mystyle
> +
>  Then simply by referencing your xml files as follows:
>
>       http://xml.server.com/myfile.xml?style=printable
> +
> +     or
> +
> +     http://xml.server.com/myfile.xml?mystyle=printable
> +
> +respectively.
>
>  You will recieve the alternate stylesheets with title "printable". See
>  the HTML 4.0 specification for more details on stylesheet choice.
> ---END QUERYSTRING DIFF---
>
>
> ---START COOKIE DIFF---
> --- Cookie.pm.orig      Thu Jul 11 12:38:09 2002
> +++ Cookie.pm   Thu Jul 11 12:37:36 2002
> @@ -12,9 +12,10 @@
>
>  sub handler {
>      my $r = shift;
> +    my $key = $r->dir_config('AxStyleChooserCookieKey') ||
> 'axkit_preferred_style';
>      my $oreo = Apache::Cookie->fetch; # if dougm can call a cookie method
> "bake". . .
> -    if ( defined $oreo->{'axkit_preferred_style'} ) {
> -        $r->notes('preferred_style',
> $oreo->{'axkit_preferred_style'}->value);
> +    if ( defined $oreo->{$key} ) {
> +        $r->notes('preferred_style', $oreo->{$key}->value);
>      }
>
>      return OK;
> @@ -36,6 +37,14 @@
>
>  This module checks for the presence of a cookie named
>  'axkit_preferred_style' and sets the preferred style accordingly.
> +
> +The name of the cookie can be changed by setting the variable
> AxStyleChooserCookieKey
> +in your httpd.conf:
> +
> +     PerlSetVar AxStyleChooserCookieKey mystyle
> +
> +Once set, this module will check for the presence of the cookie named
> 'mystyle' instead
> +of the cookie named 'axkit_preferred_style'.
>
>  Remember, use the B<title> attribute in your stylesheet PI to define a
>  matching style.
> ---END COOKIE DIFF---
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

-- 
<!-- Matt -->
<:->Get a smart net</:->


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to