diff options
| author | Jacob Kaplan-Moss | 2009-04-12 16:25:05 -0500 |
|---|---|---|
| committer | Jacob Kaplan-Moss | 2009-04-12 16:25:05 -0500 |
| commit | b5ee253b28673fcfad49f09d9d2687e86ed520b7 (patch) | |
| tree | 32f3f5939bf8d69503f443573414ea80567d095e /src/shorturls/urls.py | |
| parent | 4391a39ee4cde31ff9c9a56cd8d452b934136b4e (diff) | |
| download | django-shorturls-b5ee253b28673fcfad49f09d9d2687e86ed520b7.tar.bz2 | |
Added a working shorturl redirect view, with tests.
Diffstat (limited to 'src/shorturls/urls.py')
| -rw-r--r-- | src/shorturls/urls.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/shorturls/urls.py b/src/shorturls/urls.py new file mode 100644 index 0000000..b81e24d --- /dev/null +++ b/src/shorturls/urls.py @@ -0,0 +1,9 @@ +from django.conf import settings +from django.conf.urls.defaults import * + +urlpatterns = patterns('', + url( + regex = '^(?P<prefix>%s)(?P<tiny>\w+)$' % '|'.join(settings.SHORTEN_MODELS.keys()), + view = 'shorturls.views.redirect', + ), +)
\ No newline at end of file |
