wsgi does not work as usually even it works fine when python manage.py runserver
153.xx.x.x.x:8000/simple_project
this works.
But not when
153.xx.x.x.x/projectname/simple_project
The layout is not shown correctly because static file is not read.
django.wsgi as follows
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
import os, sys
sys.path.append('/var/www/django')
os.environ['DJANGO_SETTINGS_MODULE'] = 'projectname.settings'
import django.core.handlers.wsgi
application = django.core.handlers.wsgi.WSGIHandler()
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
static in settings.py
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
STATICFILES_DIRS = (
# Put strings here, like "/home/html/static" or "C:/www/django/static".
# Always use forward slashes, even on Windows.
# Don't forget to use absolute paths, not relative paths.
"/var/www/django/projectname/static",
)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
urls.py
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
urlpatterns = patterns('',
(r'^simple_project/add/(?P<status>\w*)$', 'simple_project.views.index'),
)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
Anyone who know a solution please giver me an advise.