Re: [Mailman-Users] changing Mailman layout
Hello, Mark Sapiro: Zbigniew Szalbot wrote: What something like that work or do I need to learn python? :) output.append('META http-equiv=Content-Type ' 'content=text/html; charset=%s' % charset) output.append('META http-equiv=Content-Type ' 'content=text/html; charset=%s' % charset \n 'link rel=stylesheet href=domain.tld/stylesheet.css type=text/css') Learning Python is always worthwhile :) The above replacement won't work for a few technical reasons. Do it this way: output.append('META http-equiv=Content-Type ' 'content=text/html; charset=%s' % charset) output.append('link rel=stylesheet ' 'href=domain.tld/stylesheet.css type=text/css') Thanks! I ran into another problem. I modified the general list information page for one of the lists. I edited it from the command line to include a style sheet in it (to test before I do it site-wide). This cannot be done via GUI. Anyway, as long as the link to a stylesheet is a full URL, all is fine. When it is a relative link (like css/stylesheet.css) or full directory path (/path/to/mailman/lists/en/css/stylesheet.css) it does not work either. Can be files referenced from directories and not by full URLs? Thanks! -- Zbigniew Szalbot www.LCWords.com -- Mailman-Users mailing list Mailman-Users@python.org http://mail.python.org/mailman/listinfo/mailman-users Mailman FAQ: http://wiki.list.org/x/AgA3 Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/ Unsubscribe: http://mail.python.org/mailman/options/mailman-users/archive%40jab.org Security Policy: http://wiki.list.org/x/QIA9
Re: [Mailman-Users] changing Mailman layout
Zbigniew Szalbot wrote: Thanks! I ran into another problem. I modified the general list information page for one of the lists. I edited it from the command line to include a style sheet in it (to test before I do it site-wide). This cannot be done via GUI. Anyway, as long as the link to a stylesheet is a full URL, all is fine. When it is a relative link (like css/stylesheet.css) or full directory path (/path/to/mailman/lists/en/css/stylesheet.css) it does not work either. Can be files referenced from directories and not by full URLs? First of all, if you think you're saving anything by including a relative or absolute path as the href= value of the stylesheet link as opposed to a URL, you are not. If you have for example in your template that becomes http://www.example.com/mailman/listinfo/list, something like link rel=stylesheet type=text/css href=css/stylesheet.css that gets sent to the browser just as is, and the browser considers that as relative to the base URL and does an HTTP GET of path /mailman/listinfo/css/stylesheet.css from www.example.com to get the style sheet. The two points are: - it is no different in terms of HTTP interaction from the case of putting an absolute URL in the href=, and - in this example at least, it doesn't work because the web server has a ScriptAlias for /mailman/ so the web server processes this request by invoking Mailman's listinfo cgi wrapper which isn't going to serve the stylesheet. You probably can specify a full directory path to the css, but the web server will still look for it relative to the servers document root, and it isn't really any different from specifying it as a URL. -- Mark Sapiro [EMAIL PROTECTED]The highway is for gamblers, San Francisco Bay Area, Californiabetter use your sense - B. Dylan -- Mailman-Users mailing list Mailman-Users@python.org http://mail.python.org/mailman/listinfo/mailman-users Mailman FAQ: http://wiki.list.org/x/AgA3 Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/ Unsubscribe: http://mail.python.org/mailman/options/mailman-users/archive%40jab.org Security Policy: http://wiki.list.org/x/QIA9
Re: [Mailman-Users] changing Mailman layout
Mark Sapiro pisze: First of all, if you think you're saving anything by including a relative or absolute path as the href= value of the stylesheet link as opposed to a URL, you are not. If you have for example in your template that becomes http://www.example.com/mailman/listinfo/list, something like link rel=stylesheet type=text/css href=css/stylesheet.css that gets sent to the browser just as is, and the browser considers that as relative to the base URL and does an HTTP GET of path /mailman/listinfo/css/stylesheet.css from www.example.com to get the style sheet. The two points are: - it is no different in terms of HTTP interaction from the case of putting an absolute URL in the href=, and - in this example at least, it doesn't work because the web server has a ScriptAlias for /mailman/ so the web server processes this request by invoking Mailman's listinfo cgi wrapper which isn't going to serve the stylesheet. You probably can specify a full directory path to the css, but the web server will still look for it relative to the servers document root, and it isn't really any different from specifying it as a URL. All this is true and I well realize that. The example with css is simple. No problem. I actually have a problem with a javascript file that the layoput designer has used. I am suspecting it won't display because I have to use a complete URL instead of a relative one as often is a case with javascripts. Maybe the same principle applies. If anyone knows, I'd be happy if you drop me a line! Thanks! Zbigniew Szalbot -- Mailman-Users mailing list Mailman-Users@python.org http://mail.python.org/mailman/listinfo/mailman-users Mailman FAQ: http://wiki.list.org/x/AgA3 Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/ Unsubscribe: http://mail.python.org/mailman/options/mailman-users/archive%40jab.org Security Policy: http://wiki.list.org/x/QIA9
Re: [Mailman-Users] changing Mailman layout
Zbigniew Szalbot wrote: All this is true and I well realize that. The example with css is simple. No problem. I actually have a problem with a javascript file that the layoput designer has used. I am suspecting it won't display because I have to use a complete URL instead of a relative one as often is a case with javascripts. Maybe the same principle applies. If anyone knows, I'd be happy if you drop me a line! Any relative reference to anything on a page that is served by a Mailman CGI is going to be relative to that CGI and will re-invoke the CGI. Whether or not it works depends on the context: For example, if there were a tag like a href=listname on the page served by http://www.example.com/mailman/listinfo/ (there isn't, but), that would work because it is equivalent to http://www.example.com/mailman/listinfo/listname which is a URL that does the expected thing. Although, even that wouldn't work if the URL that invoked the page didn't end with '/'. OTOH, a reference to some/javascript is not going to work because http://www.example.com/mailman/listinfo/some/javascript is not going to serve the javascript; it's going to attempt to serve the listinfo page for the list named some. -- Mark Sapiro [EMAIL PROTECTED]The highway is for gamblers, San Francisco Bay Area, Californiabetter use your sense - B. Dylan -- Mailman-Users mailing list Mailman-Users@python.org http://mail.python.org/mailman/listinfo/mailman-users Mailman FAQ: http://wiki.list.org/x/AgA3 Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/ Unsubscribe: http://mail.python.org/mailman/options/mailman-users/archive%40jab.org Security Policy: http://wiki.list.org/x/QIA9
Re: [Mailman-Users] changing Mailman layout
Mark Sapiro pisze: OTOH, a reference to some/javascript is not going to work because http://www.example.com/mailman/listinfo/some/javascript is not going to serve the javascript; it's going to attempt to serve the listinfo page for the list named some. Thank you Mark - do I read it correctly that javascript files won't work and the only thing to do is get rid of it and define graphics in the css style sheet? Zbigniew Szalbot -- Mailman-Users mailing list Mailman-Users@python.org http://mail.python.org/mailman/listinfo/mailman-users Mailman FAQ: http://wiki.list.org/x/AgA3 Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/ Unsubscribe: http://mail.python.org/mailman/options/mailman-users/archive%40jab.org Security Policy: http://wiki.list.org/x/QIA9
Re: [Mailman-Users] changing Mailman layout
Zbigniew Szalbot wrote: Mark Sapiro pisze: OTOH, a reference to some/javascript is not going to work because http://www.example.com/mailman/listinfo/some/javascript is not going to serve the javascript; it's going to attempt to serve the listinfo page for the list named some. Thank you Mark - do I read it correctly that javascript files won't work and the only thing to do is get rid of it and define graphics in the css style sheet? No. That isn't the question I thought I was answering. I was only saying that references to files on the server which you include in a template all need to be absolute. This may extend to references within the included files; I'm not sure about that. The other point is you have a lot of flexibility when editing templates, but for pages not generated from templates, e.g. the listinfo overview page, you have to actually modify Mailman code. Earlier in this thread, I indicated a simple way to include a style sheet reference in all such pages. You could also include definitions of javascript functions in the same way, but actually calling those functions in the body of the page would require further modifications. -- Mark Sapiro [EMAIL PROTECTED]The highway is for gamblers, San Francisco Bay Area, Californiabetter use your sense - B. Dylan -- Mailman-Users mailing list Mailman-Users@python.org http://mail.python.org/mailman/listinfo/mailman-users Mailman FAQ: http://wiki.list.org/x/AgA3 Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/ Unsubscribe: http://mail.python.org/mailman/options/mailman-users/archive%40jab.org Security Policy: http://wiki.list.org/x/QIA9
Re: [Mailman-Users] changing Mailman layout
Hi all, The best way to add css or similar things to these pages is to modify the Format() method of the Document() class in Mailman/htmlformat.py. What something like that work or do I need to learn python? :) output.append('META http-equiv=Content-Type ' 'content=text/html; charset=%s' % charset) output.append('META http-equiv=Content-Type ' 'content=text/html; charset=%s' % charset \n 'link rel=stylesheet href=domain.tld/stylesheet.css type=text/css') Many thanks for further ideas! -- Zbigniew Szalbot www.LCWords.com -- Mailman-Users mailing list Mailman-Users@python.org http://mail.python.org/mailman/listinfo/mailman-users Mailman FAQ: http://wiki.list.org/x/AgA3 Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/ Unsubscribe: http://mail.python.org/mailman/options/mailman-users/archive%40jab.org Security Policy: http://wiki.list.org/x/QIA9
Re: [Mailman-Users] changing Mailman layout
Zbigniew Szalbot wrote: What something like that work or do I need to learn python? :) output.append('META http-equiv=Content-Type ' 'content=text/html; charset=%s' % charset) output.append('META http-equiv=Content-Type ' 'content=text/html; charset=%s' % charset \n 'link rel=stylesheet href=domain.tld/stylesheet.css type=text/css') Learning Python is always worthwhile :) The above replacement won't work for a few technical reasons. Do it this way: output.append('META http-equiv=Content-Type ' 'content=text/html; charset=%s' % charset) output.append('link rel=stylesheet ' 'href=domain.tld/stylesheet.css type=text/css') -- Mark Sapiro [EMAIL PROTECTED]The highway is for gamblers, San Francisco Bay Area, Californiabetter use your sense - B. Dylan -- Mailman-Users mailing list Mailman-Users@python.org http://mail.python.org/mailman/listinfo/mailman-users Mailman FAQ: http://wiki.list.org/x/AgA3 Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/ Unsubscribe: http://mail.python.org/mailman/options/mailman-users/archive%40jab.org Security Policy: http://wiki.list.org/x/QIA9
[Mailman-Users] changing Mailman layout
Dear all, Where do I look to change Mailman layout (I know where to change individual lists) but not sure where are files for domian.tld/mailman/listinfo located. I'd like to customize Mailman to look more like our organization's website. Many thanks in advance! -- Zbigniew Szalbot www.LCWords.com -- Mailman-Users mailing list Mailman-Users@python.org http://mail.python.org/mailman/listinfo/mailman-users Mailman FAQ: http://wiki.list.org/x/AgA3 Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/ Unsubscribe: http://mail.python.org/mailman/options/mailman-users/archive%40jab.org Security Policy: http://wiki.list.org/x/QIA9
Re: [Mailman-Users] changing Mailman layout
Zbigniew Szalbot wrote: Where do I look to change Mailman layout (I know where to change individual lists) but not sure where are files for domian.tld/mailman/listinfo located. The listinfo overview page is built on the fly by Mailman/Cgi/listinfo.py. The admin(db) pages are built the same way by Mailman/Cgi/admin(db).py. The best way to add css or similar things to these pages is to modify the Format() method of the Document() class in Mailman/htmlformat.py. If you really want to add, subtract or rearrange things on these pages, you have to modify the Mailman/Cgi/* modules that generate them. -- Mark Sapiro [EMAIL PROTECTED]The highway is for gamblers, San Francisco Bay Area, Californiabetter use your sense - B. Dylan -- Mailman-Users mailing list Mailman-Users@python.org http://mail.python.org/mailman/listinfo/mailman-users Mailman FAQ: http://wiki.list.org/x/AgA3 Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/ Unsubscribe: http://mail.python.org/mailman/options/mailman-users/archive%40jab.org Security Policy: http://wiki.list.org/x/QIA9