Opened 19 years ago
Closed 18 years ago
#2891 closed enhancement (fixed)
Usabiliity: Redirect user to the comment just posted to provide feedback
Reported by: | Huvet | Owned by: | darkfate |
---|---|---|---|
Milestone: | 2.1 | Priority: | normal |
Severity: | normal | Version: | 2.0.4 |
Component: | Administration | Keywords: | bg|has-patch bg |
Focuses: | Cc: |
Description
After posting a comment the user does not get any feedback that everything everything worked. The user is set to the top of the page and on a site with lots of content he will be forced to scroll down and look for the comment in the masses.
The solution to this is simple. Redirect the user to the comment just posted. This can be done by changing one line in wp-comments-post.php:
Line 61 from:
wp_redirect( $location );
Line 61 to:
wp_redirect( $location . "#" . $comment_post_ID );
This would be a great usability enhancement.
Attachments (1)
Change History (21)
#2
@
19 years ago
Yea, I get it.
This would work:
wp_redirect( $location . "#comment-" . $comment_id );
#3
@
19 years ago
- Keywords bg|has-patch bg added
- Milestone set to 2.0.4
- Owner changed from anonymous to darkfate
#4
@
19 years ago
- Type changed from defect to enhancement
Is the "comment-" prefix standardized enough? Since what comes after '#' depends on themes, I prefer to do this as a plugin.
#6
@
19 years ago
OK, it is in the template, but I think it's a pretty standard way to make comments.
#7
@
19 years ago
As long as it uses the standard way used by Default and Classic themes, I'm fine with hardcoding it. If theme authors want that to work, they can follow that convention.
#8
@
19 years ago
Is this going to be committed into the trunk? If it is, is it going to be in 2.0.4 or 2.1? Or should we get a second opinion?
#10
@
19 years ago
While I have checked the theme directory, it seems a pretty much standard way. I see no problem hardcoding it. (Please ignore my previous comment.)
#11
@
19 years ago
I love the idea, I was just wondering about all this a few weeks ago. =) I'll try this out once and see what happens, and if I decide to make up some themes, I'll surely take this route. ;) :) *It really does suck to have to scroll all the way down the page, especially on lengthy content based blogs sigh. =(
#12
@
19 years ago
OMFG! I love this!! I just tested it on the localhost, and it works just beautifully.. =D Of course, I haven't tested it without javascript on, but it *shouldn't* need that anyways right? lol.. I would really love to see this added in before 2.0.4. ;) Can someone please post the possible "yays" or "nays" about this.. =/
#13
@
19 years ago
We had this before and took it out, because people would not see their comment and submit it again and again.
#14
@
19 years ago
Oh ok matt.. I must have not noticed it before, because at that "time", I wasn't really posting comments on my own blog lol. =P I'll leave it up on my main blog though for the time being..
#15
@
19 years ago
matt: What made it _harder_ for them to see the comment if it got focused? Sounds very strange to me. On my site (http://friendlybit.com) I have the comments in the sidebar and since I switched to using this redirect (thanks darkfate) people have stopped complaining. I'm not sure what users you tested this on but mine like it this way.
I suggest you include it into 2.0.4.
I'm all open for other ideas and compromises, I just find it annoying to have to add this in again every time I update. The main problem is that people don't get any feedback that confirms they have posted a comment and that's a BIG problem.
#16
@
19 years ago
Maybe the redirect I made should be put in and then you can have like a javascript window or something that says "Thank you for posting your comment". Like so:
<script language="Javascript"> <!-- alert ("Thank you posting your comments!") //--> </script>
#17
@
19 years ago
or if you want to do it the valid way! ;)
<script type="text/javascript"> <!-- alert ("This is a Javascript Alert") //--> </script>
Ok, that code change does not seem to work after all, I'm sure you get what I'm after anyway.