[Mailman-Users] Help with a regular expression

Greg Westin greg at gregwestin.com
Sat Jan 18 15:46:31 CET 2003

I think what you want to do to fix this is add a carat ("^") before the  
first slash:
RedirectMatch ^/mailman[/]*$ http://www.example.com/mailman/listinfo

That way, it only catches it if "/mailman" occurs at the beginning of  
the string.

Personally, I use a little more inclusive regular expression, because I  
want it to also redirect any requests for the top level  
(http://lists.example.com) to the listinfo page:
     RewriteRule ^[/]{0,1}(mailman[/]{0,1}){0,1}$    /mailman/listinfo  

I claim to be no master of regular expressions, though... because wow  
that looks ugly.  That notwithstanding, I think my advice on your  
situation is correct.


On Saturday, January 18, 2003, at 02:09  AM, Paul Kleeberg wrote:

> I know this is a simple question but I don't have the knowledge to  
> figure it out.
> I am running RedHat 8.0 and which came with Mailman 2.0.13.  It  
> suggests adding the following to the httpd.conf file:
> # Uncomment the following line, replacing www.example.com with your  
> server's
> # name, to redirect queries to /mailman to the listinfo page  
> (recommended).
> # RedirectMatch /mailman[/]*$ http://www.example.com/mailman/listinfo
> That used to work fine.  I just upgraded to Mailman 2.1.  I created  
> the list "mailman" as instructed at the end of section 4 of the  
> INSTALL document but cannot get to the administrative page  
> http://www.example.com/mailman/admin/mailman or the list overview page  
> http://www.example.com/mailman/listinfo/mailman because  
> "RedirectMatch" thinks it is http://www.example.com/mailman and just  
> redirects it the top level listinfo page.
> I am aware that I have two options:
>   1. Rename the "mailman" list
>   2. Remove the "RedirectMatch" statement from the httpd.conf file.
> Is there a third?  I tried fiddling with the regular expression, but I  
> just do not know what I am doing.  Any help would be appreciated.
> Paul
> --  
> Paul Kleeberg, M.D.              O   o          paul at fpen.org
> Family Physicians' E-Net        -+---+-   Voice: 612-840-3744
> 5025 Mulcare Drive               |_o_|      Family Practice &
> Columbia Heights, MN 55421 USA  / \|/ \  Information Services
> ------------------------------------------------------
> Mailman-Users mailing list
> Mailman-Users at python.org
> http://mail.python.org/mailman/listinfo/mailman-users
> Mailman FAQ: http://www.python.org/cgi-bin/faqw-mm.py
> Searchable Archives:  
> http://www.mail-archive.com/mailman-users%40python.org/
> This message was sent to: greg at gregwestin.com
> Unsubscribe or change your options at
> http://mail.python.org/mailman/options/mailman-users/ 
> greg%40gregwestin.com
Contact info: http://www.gregwestin.com/contact.php

More information about the Mailman-Users mailing list