Ask Your Question
1

what is ASKBOT_URL setting supposed to do?

asked 2013-06-08 10:18:13 -0500

pajju gravatar image

updated 2013-06-08 10:20:09 -0500

what is the setting ASKBOT_URL setting supposed to do?

###########################
#
#   this will allow running your forum with url like http://site.com/forum
#
#   ASKBOT_URL = 'forum/'
#
ASKBOT_URL = '' #no leading slash, default = '' empty string
  • My requirement is to — host askbot in a subpath like: mysite.com/forum
  • And mysite.com/ will host some another webapp(say, a wordpress CMS)

Basically I'm running multiple webapps under the same domain, but each webapp is hosted within a unique sub-path.

Thanks.

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted
1

answered 2013-06-08 10:27:26 -0500

Evgeny gravatar image

Like you might have suspected, this is for hosting askbot at sub-url.

You might also need to add FORCE_SCRIPT_NAME setting to keep the url prefix of the original request.

Here is a blog post explaining how this can be done (there are other posts too):

http://lazylabs.org/blog/django-under-sub-url-powered-by-uwsgi-behind-nginx/

The ASKBOT_URL is used in the urls.py file and is needed for the routing as well as for the correct result of reverse() calls - so that all urls printed in the html output have the prefix.

edit flag offensive delete link more

Comments

Thanks.

Yeah, we can set FORCE_SCRIPT_NAME = "/subpath" and this should handle everything right, i.e internal app routing.

But, In what cases, do we need to touch ASKBOT_URL?

pajju gravatar imagepajju ( 2013-06-08 10:52:23 -0500 )edit
1

The ASKBOT_URL is necessary if you use stock urls.py - otherwise - depending on how you've built the urls config file.

Evgeny gravatar imageEvgeny ( 2013-06-08 11:03:22 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2013-06-08 10:18:13 -0500

Seen: 339 times

Last updated: Jun 08 '13