mirror of
https://github.com/postgres/pgweb.git
synced 2025-08-06 09:57:57 +00:00
Add module for legacy URLs, add legacy URLs for press
This commit is contained in:
0
pgweb/legacyurl/__init__.py
Normal file
0
pgweb/legacyurl/__init__.py
Normal file
3
pgweb/legacyurl/models.py
Normal file
3
pgweb/legacyurl/models.py
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
from django.db import models
|
||||||
|
|
||||||
|
# Create your models here.
|
6
pgweb/legacyurl/views.py
Normal file
6
pgweb/legacyurl/views.py
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
from django.http import HttpResponse, Http404, HttpResponseRedirect
|
||||||
|
|
||||||
|
def presskit(self, version, language):
|
||||||
|
return HttpResponseRedirect("/about/press/presskit%s/%s/" % (
|
||||||
|
version, language)
|
||||||
|
)
|
@ -66,6 +66,12 @@ urlpatterns = patterns('',
|
|||||||
###
|
###
|
||||||
(r'account/', include('account.urls')),
|
(r'account/', include('account.urls')),
|
||||||
|
|
||||||
|
###
|
||||||
|
# Legacy URLs from the old website, that are likely to be used from other
|
||||||
|
# sites or press releases or such
|
||||||
|
###
|
||||||
|
(r'^about/press/presskit(\d+).html.(\w+)$', 'pgweb.legacyurl.views.presskit'),
|
||||||
|
|
||||||
# Uncomment the next line to enable the admin:
|
# Uncomment the next line to enable the admin:
|
||||||
(r'^admin/(.*)', admin.site.root),
|
(r'^admin/(.*)', admin.site.root),
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user