## page was renamed from DOC/4.48 How can I change the HTML (or .txt) templates used by my mailing lists? #pragma page-filename DOC/versions/4030605 == 4.48. How can I change the HTML (or .txt) templates used by my mailing lists? == === From the web interface: === If you click on "Edit the public HTML pages and text files" under "Other Administrative Activities" on the upper right hand side of the logged in admin page, you can edit the following from the web interface: * General list information page * Subscribe results page * User specific options page * Welcome email text file * Digest masthead (starting with mailman 2.1.15) and starting with Mailman 2.1.23 * User notice of held post * User notice of held subscription * Notice of post refused by moderator * Invitation to join list * Request to confirm subscription * Request to confirm unsubscription * User notice of autoresponse limit * User post acknowledgement * Subscription disabled by bounce warning * Admin/moderator login page * Private archive login page * On demand password reminder The direct link to this editing page will look something like [[http://EXAMPLE.COM/mailman/edithtml/LISTNAME|http://EXAMPLE.COM/mailman/edithtml/LISTNAME]] where you replace the sections in caps with your web domain and listname, respectively. === From the server: === Richard Barrett has answered this question in two excellent messages on the mailman-users mailing list. See [[http://mail.python.org/pipermail/mailman-users/2004-June/037497.html|http://mail.python.org/pipermail/mailman-users/2004-June/037497.html]] and [[http://mail.python.org/pipermail/mailman-users/2004-June/037650.html|http://mail.python.org/pipermail/mailman-users/2004-June/037650.html]]. Summarizing from these messages: The archiver maintains a template cache, so if you create edited versions of any archive related templates, you need to restart Mailman to get the qrunner to restart so that it will rebuild its template cache and in the process pick up new or changed templates. Non-archive related templates are not cached so any edits or new domain or list specific templates will be effective immediately without a restart. Note that /bin/arch always starts with its own empty template cache each time it runs. Also: You should put your site and list specific changes as described in these comments form $prefix/Mailman/Utils.py: {{{ # Make some text from a template file. The order of searches depends on # whether mlist and lang are provided. Once the templatefile is found, # string substitution is performed by interpolation in `dict'. If `raw' # is false, the resulting text is wrapped/filled by calling wrap(). # # When looking for a template in a specific language, there are 4 places # that are searched, in this order: # # 1. the list-specific language directory # lists// # # 2. the domain-specific language directory # templates// # # 3. the site-wide language directory # templates/site/ # # 4. the global default language directory # templates/ # # The first match found stops the search. In this way, you can specialize # templates at the desired level, or, if you use only the default # templates, you don't need to change anything. You should never modify # files in the templates/ subdirectory, since Mailman will # overwrite these when you upgrade. That's what the templates/site # language directories are for. # # A further complication is that the language to search for is determined # by both the `lang' and `mlist' arguments. The search order there is # that if lang is given, then the 4 locations above are searched, # substituting lang for . If no match is found, and mlist is # given, then the 4 locations are searched using the list's preferred # language. After that, the server default language is used for # . If that still doesn't yield a template, then the standard # distribution's English language template is used as an ultimate # fallback. If that's missing you've got big problems. ;) }}} In [[http://mail.python.org/pipermail/mailman-users/2004-October/040452.html|http://mail.python.org/pipermail/mailman-users/2004-October/040452.html]], Mark Sapiro notes: {{{ If you want the "Subscribe results page" it is subscribe.html and it can also be edited via the lists "Edit the public HTML pages" link. }}} {{{ If you want the e-mail welcome message, it's subscribeack.txt. }}} {{{#!wiki caution The monthly password reminder template is cronpass.txt, and it is sent without a list context so a list specific or domain specific version of this template will not work, even if the list is the site list. }}} Converted from the Mailman FAQ Wizard This is one of many [[../Frequently Asked Questions|Frequently Asked Questions]]. ---- <>