is an app that allows new django developers to have a user_profile app to there django projects.
this app creates a user_profile instance automatically the user is added to the default django User
model.
-
install required dependancies in the
requirements.txt
file. -
add
user_profile
toINSTALLED_APPS
. -
add
url(r'^profile/', include('user_profile.urls')),
in your mainurls.py
file. -
run
python manage.py makemigrations
thenpython manage.py migrate
. -
add
os.path.join(BASE_DIR, 'user_profile/cdn/staticfiles')
to your STATICFILES_DIRS such that it looks likeSTATICFILES_DIRS = [ ... os.path.join(BASE_DIR, 'user_profile/cdn/staticfiles'), ... ]
-
for styling add
<link href="{% static 'user_profile/css/profile.css' %}" rel="stylesheet">
to yourbase.html
-
the app provides
{% update_link %}
and{% profile_link %}
tags which is accessed by adding{% load navigation_links %}
at the top of thehtml file
.