November 2015
Beginner to intermediate
840 pages
26h 30m
English
ProfileDetailCreating a public profile view is quite straightforward, so I opt to take on the stranger case first. In the case of our ProfileDetail view, shown in Example 22.5, we want to show the user’s own profile at a static (without regular expression character sets) URL: /user/profile/.
Example 22.5: Project Code
10 from .views import ( 11 ActivateAccount, CreateAccount, 12 DisableAccount, ProfileDetail, 13 ResendActivationEmail) . ... 67 urlpatterns = [ . ... 108 url(r'^profile/$', 109 ProfileDetail.as_view(), 110 name='profile'), 111 ]
To properly display the profile of the current User, ...
Read now
Unlock full access