Django URL Shortener is a Django app to to include URL Shortening feature in your Django Project.
Project description
===== Django URL Shortener
Django URL Shortener is a Django app to to include URL Shortening feature in your Django Project
Detailed documentation is in the "docs" directory.
Quick start
-
Add "django_url_shortener" to your INSTALLED_APPS setting like this::
INSTALLED_APPS = [ ... 'django_url_shortener', ]
-
Include the polls URLconf in your project urls.py like this::
path('s/', include('django_url_shortener.urls')),
-
Run
python manage.py migrate
to create the polls models. -
[Optional] Upate configs in settings.py SHORTCODE_MIN = 4 SHORTCODE_MAX = 20 BASE_URL = "https://mysite.com"
-
Import shorten_url method from django_url_shortener.utils import shorten_url
-
Shorten your URL
created, short_url = shorten_url("https://github.com/rishav00a/django_url_shortener") created, short_url = shorten_url("https://github.com/rishav00a/django_url_shortener/issues","xyzw")
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Hashes for django-url-shortener-app-0.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0b0bd54cc0a97f06682f139588d07f8dea8d9cdb1264c3bf85de999c2ca561a6 |
|
MD5 | 8e324542d77c49238e36c607bee5c25a |
|
BLAKE2b-256 | 0717c34edf23f84ddf393d5397a330eba3f6e1b5f17dfae5bbbd720957097767 |