[Moin-user] Correct value for "url_prefix" in "wikiconfig.py"
Nir Soffer
nirs at freeshell.org
Fri Mar 17 00:25:13 EST 2006
On 16/03/2006, at 23:06, Fred Drake wrote:
> On 3/16/06, Kenneth McDonald <kenneth.m.mcdonald at sbcglobal.net> wrote:
>> # This must be '/wiki' for twisted and standalone. For CGI, it should
>> # match your Apache Alias setting.
>> url_prefix = '/home/sites/home/web'
>>
>> The value I have there right now is my system's DocumentRoot setting.
>> the httpd.conf doesn't include an Alias directive, so I'm not quite
>> sure
>> what I should do here.
>
> DocumentRoot is a path on the local system; url_prefix is a path
> within the browser-accessible web space. For instance, if your wiki
> FrontPage is accessed as
>
> http://www.example.net/mywiki/FrontPage
>
> then url_prefix should be "/mywiki".
No! don't listen to Fred, you may loose your wiki :-)
url_prefix has nothing to do with your wiki name, and they should never
be the same.
url_prefix is the url prefix of moin static files (css and images). For
example:
http://yourdomain/wiki/modern/css/screen.css
While your wiki url look like this:
http://yourdomain/mywiki/pagename
Back to the question, how do you set this value? Just leave this as is,
"/wiki". This value is used by moin when it creates links to static
files (If you look into the html source, you will find those urls).
Now, what Apache is going to do with
"http://yourdomain/wiki/modern/css/screen.css"? there is no "wiki"
directory in your document root. Thats why you need the Alias
configuration:
Alias /wiki/ /usr/share/moin/htdocs/
This tell Apache that any url that starts with /wiki/, should be served
from the path "/usr/share/moin/htdocs/". This path should be adapted to
your installation.
Best Regards,
Nir Soffer
More information about the Moin-user
mailing list