Opened 19 years ago

Closed 19 years ago

Last modified 17 years ago

#893 closed defect (fixed)

"change password" and "log out" on admin site doesn't work on apache2

Reported by: wangbin@… Owned by: Adrian Holovaty
Component: contrib.admin Version:
Severity: normal Keywords:
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: yes
Needs tests: yes Patch needs improvement: yes
Easy pickings: no UI/UX: no

Description

When I setup a django project with apache2 and mod_python, the "change password" and "log out" on admin site doesn't work, I think the link in base.html should not be "/admin/password_change/", it should be "password_change/".

Attachments (2)

admin-templates.diff (2.3 KB ) - added by deric <deric@…> 19 years ago.
admin-templates2.diff (1.3 KB ) - added by deric <deric@…> 19 years ago.
svn diff delete_confirmation.html object_history.html

Download all attachments as: .zip

Change History (8)

comment:1 by deric <deric@…>, 19 years ago

works for me apache2/mod_python revision 1474

[28/Nov/2005 00:52:04] "GET /admin/password_change/ HTTP/1.1" 200 2089
[28/Nov/2005 00:52:14] "POST /admin/password_change/ HTTP/1.1" 302 0
[28/Nov/2005 00:52:14] "GET /admin/password_change/done/ HTTP/1.1" 200 1256
[28/Nov/2005 00:52:19] "GET /admin/logout/ HTTP/1.1" 302 0
[28/Nov/2005 00:52:19] "GET /admin/logout/ HTTP/1.1" 200 1087

comment:2 by lawgon@…, 19 years ago

Severity: normalmajor

my site admin is in:
http://mydomain.com/myproject/admin/
on clicking 'logout' the browser goes to:
http://mydomain.com/admin/logout/ and not to:
http://mydomain.com/myproject/admin/logout/ as it was doing earlier

comment:3 by lawgon@…, 19 years ago

on discussion in IRC it is found that this error is there for sites that do not have admin on '/'. Where admin is on '/' it works

by deric <deric@…>, 19 years ago

Attachment: admin-templates.diff added

comment:4 by deric <deric@…>, 19 years ago

Severity: majornormal

As explained above this has been identified to possibly be due to absolute URLs for the links in the admin interface. Presumably relative URLs would work fine since you'd be in the admin app whatever URL that might be at. I've attached a patch for the basic change-templates. I'm not sure if this will work for all the templates. I'm in a bit of a hurry... will look into it later unless someone else steps up...

by deric <deric@…>, 19 years ago

Attachment: admin-templates2.diff added

svn diff delete_confirmation.html object_history.html

comment:5 by deric <deric@…>, 19 years ago

the diffs are collectively inclusive. merge both.

comment:6 by Adrian Holovaty, 19 years ago

Resolution: fixed
Status: newclosed

(In [1521]) Fixed #893 -- Admin 'change password' and 'log out' links no longer assume admin lives at '/admin/'. Thanks, deric@…

Note: See TracTickets for help on using tickets.
Back to Top