[Mailman-Users] Shortening URLS

Greg Ward gward at mems-exchange.org
Fri Oct 26 00:15:02 CEST 2001


On 25 October 2001, Michael H Moran said:
> Running mailman 2.0.6, on Linux with Apache,  is there a way to 
> shorten the URL to the listinfo page for a specific list ?
> 
> i.e.   http://<hostname>/mailman/listinfo/<list name>
> becomes
>        http://<hostname>/<list name> 

This should be doable with a simple RewriteRule.

Try this:
  RewriteRule ^/foo-list$ /mailman/listinfo/foo-list

If you have many lists whose names all end in "-list":
  RewriteRule ^/([^/]*)-list$ /mailman/listinfo/$1-list

If you have a couple of lists with variable names:
  RewriteRule ^/(foo-list|bar-devel|qux-users)$ /mailman/listinfo/$1

You get the idea (I hope).  These are all completely untested and off
the top of my head.

> RTFM-ing, didn't provide any clues.  

Which FM?  This is really an Apache question.  See the docs for the
rewrite engine:
  http://httpd.apache.org/docs/mod/mod_rewrite.html

The biggest gotcha is that you have to do "RewriteEngine on" *for each
virtual host* in your http.conf.

        Greg




More information about the Mailman-Users mailing list