sphinx_django/urls.py
changeset 3 de4a2ed2f34b
parent 2 f5e18f8ed036
equal deleted inserted replaced
2:f5e18f8ed036 3:de4a2ed2f34b
     1 from django.conf.urls.defaults import *
     1 from django.conf.urls.defaults import *
     2 from django.contrib import admin
     2 from django.contrib import admin
       
     3 import os
     3 # Uncomment the next two lines to enable the admin:
     4 # Uncomment the next two lines to enable the admin:
     4 # from django.contrib import admin
     5 # from django.contrib import admin
     5 admin.autodiscover()
     6 admin.autodiscover()
     6 
     7 
     7 urlpatterns = patterns('',
     8 urlpatterns = patterns('',
    11     (r'^test/','sphinxcomment.views.test' ),
    12     (r'^test/','sphinxcomment.views.test' ),
    12     (r'chapter/', 'sphinxcomment.views.chapter'),
    13     (r'chapter/', 'sphinxcomment.views.chapter'),
    13     (r'count/(?P<chapter_name>.+)?$', 'sphinxcomment.views.chapter_count'),                  
    14     (r'count/(?P<chapter_name>.+)?$', 'sphinxcomment.views.chapter_count'),                  
    14     (r'single/(?P<paragraph_id>[^/]+)/$', 'sphinxcomment.views.single'),
    15     (r'single/(?P<paragraph_id>[^/]+)/$', 'sphinxcomment.views.single'),
    15     (r'submit/(?P<paragraph_id>[^/]+)/$', 'sphinxcomment.views.submit'),
    16     (r'submit/(?P<paragraph_id>[^/]+)/$', 'sphinxcomment.views.submit'),
    16     (r'^static/(?P<path>.*)$', 'django.views.static.serve',
       
    17      {'document_root': '/home/amit/review/sttp_test/_build/commenthtml'}),
       
    18                        
       
    19     # Uncomment the admin/doc line below and add 'django.contrib.admindocs' 
    17     # Uncomment the admin/doc line below and add 'django.contrib.admindocs' 
    20     # to INSTALLED_APPS to enable admin documentation:
    18     # to INSTALLED_APPS to enable admin documentation:
    21     # (r'^admin/doc/', include('django.contrib.admindocs.urls')),
    19     # (r'^admin/doc/', include('django.contrib.admindocs.urls')),
    22 
    20 
    23     # Uncomment the next line to enable the admin:
    21     # Uncomment the next line to enable the admin:
    24      (r'^admin/', include(admin.site.urls)),
    22      (r'^admin/', include(admin.site.urls)),
       
    23      (r'^pages/_static/(?P<path>.*)$', 'django.views.static.serve',
       
    24      {'document_root': os.path.join(os.getcwd(),'static')}),
       
    25                     
       
    26      (r'^pages/(?P<path>.*)$', 'sphinxcomment.views.page'),
    25 )
    27 )