|
From: will kahn-g. <wi...@bl...> - 2010-11-02 13:50:24
|
SCRIPT_NAME is an environment variable that comes from whatever environment you're running PyBlosxom in. It shouldn't be the full path--it should be the path from which the script was executed. It's a pretty standard CGI variable. How does your environment build the SCRIPT_NAME variable? Regardless, the documentation encourages you to set the base_url in your config.py file if it's not getting generated correctly for your situation. I set it in my config.py file because I use mod_rewrite for url rewriting. /will On 11/02/2010 09:25 AM, Dieter Plaetinck wrote: > Hi, > I'm using the latest 1.5 code from git > > my flavours/html.flav/head contains: > > <a href="$(base_url)/">$(blog_title)</a> > > When I go to http://localhost/ this works fine: I see my blog with all > entries, but then, I click a link to see an individual entry, say > http://localhost/back_from_canada_archcon.html > > this page shows fine, i see the entry i wanted to see, > but the $base_url is now the current page +'/', so the link to take me > home points to http://localhost/back_from_canada_archcon.html/ > which, btw, shows the home page > So I can go to http://localhost/back_from_canada_archcon.html/, and > click on any entry to see it, say: > http://localhost/back_from_canada_archcon.html/arch_linux_interview_and_uzbl_article.html > when I'm there, the $base_url is again > http://localhost/back_from_canada_archcon.html/ > > To be sure, i disabled all plugins (and restarted the webserver) but > the issue stays the same. > > > Another thing, which is probably related: if i have enabled the tags > plugin (took the latest one from git) > and I am at http://localhost, then click on a tag-link, say: > http://localhost/tag/foss > it says: > "The page you are looking for is not available > Somehow I cannot find the page you want." and $base_url is now > http://localhost/tag/ > > I know I can define $base_url in config.py, but I don't see why that > should be needed, since my webserver does not do anything fancy like > url rewriting, pyblosxom should be able to get the correct base_url by > itself right? > > so I checked the code, more specifically class PyBlosxom , > function initialize(), where I see SCRIPT_NAME from the http > environment is stored in the base_url. > > And SCRIPT_NAME, when visiting > http://localhost/back_from_canada_archcon.html > is: > /back_from_canada_archcon.html/ > > Is this normal? I couldn't immediately figure out what the SCRIPT_NAME > is supposed to be. Is this a bug with my webserver or my setup? (I use > lighttpd 1.4.28, my config is at http://sprunge.us/JCCO, the fastcgi > script is at > http://github.com/Dieterbe/dieterblog/blob/manageable/fcgi.py) > > Thanks, > Dieter > > ------------------------------------------------------------------------------ > Nokia and AT&T present the 2010 Calling All Innovators-North America contest > Create new apps & games for the Nokia N8 for consumers in U.S. and Canada > $10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing > Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store > http://p.sf.net/sfu/nokia-dev2dev > _______________________________________________ > pyblosxom-users mailing list > pyb...@li... > https://lists.sourceforge.net/lists/listinfo/pyblosxom-users > |