Opened 16 years ago
Closed 16 years ago
#10735 closed (fixed)
Comment redirect breaks if you want to send get data
Reported by: | Nate | Owned by: | nobody |
---|---|---|---|
Component: | contrib.comments | Version: | dev |
Severity: | Keywords: | ||
Cc: | Triage Stage: | Unreviewed | |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
I'm making a site where you can view models in sets, and the sets are specified with GET. So you may have a url like /entries/?set=first or something. With the django comment system, you can have the form redirect by setting "next" in a hidden field or the like, and the comment form redirects there when it's done. However, it sends get data of its own, and assumes that the url in "next" doesn't already have get data. In my case it does. Thus, django comments just sticks "?c=whatever" on the end of my url, which is wrong. I've supplied a patch that simply checks if the url has GET data (I just search for ".*?[/]*$", which is probably horribly wrong, but it works for my intents and purposes), and if that matches, comments uses "&" instead of "?".
Attachments (1)
Change History (3)
by , 16 years ago
Attachment: | comment_redirect_bug.diff added |
---|
Your problem seems genuine, but can you please follow the coding style
adopted in django.