hi,
im trying django-profiles and i like it but im not understanding why if
a profile does not exist it has to output a http404. i think it doesnt
has really much sense because if a profile is not yet created or not
public it shouldnt give a 404 but a "im sorry but the profile is not
available because has not been created or its not public".
i looked at the profile_detail view and im trying to redirect to a
"profile_does_not_exist" template but im experiencing problems because
the profile request is made with a get_profile_or_404 method and i cant
do a HttpResponseRedirect like:
user = get_object_or_404(User, username=username)
try:
profile_obj = user.get_profile()
except ObjectDoesNotExist:
return HttpResponseRedirect('http://some/url/')
right?!
how could i redirect to another template, view if the profile doesnt
exist instead of the actual 404??
i appreciate any help!
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---