[wp-trac] [WordPress Trac] #11870: categories.php does not redirect to front-end.
WordPress Trac
wp-trac at lists.automattic.com
Tue Jan 12 04:57:12 UTC 2010
#11870: categories.php does not redirect to front-end.
----------------------------+-----------------------------------------------
Reporter: mfields | Owner: dancole
Type: defect (bug) | Status: assigned
Priority: normal | Milestone: Unassigned
Component: Administration | Version: 2.9.1
Severity: normal | Keywords: close
----------------------------+-----------------------------------------------
Comment(by mfields):
Replying to [comment:2 scribu]:
> The current code restricts redirection to the current admin page. I
don't know why that restriction is in place. Perhaps someone has any info
on that.
>
> I do know that the proposed solution isn't good:
>
> With the current patch, if you're on wp-admin/categories.php?pagenum=2
and you edit a category, you will loose the ?pagenum=2 part.
Ahhh... good catch, My test installation did not have enough categories to
test this - sorry for the oversight. I have reproduced this and have
worked out another possible solution. I appears that the conditional
statement ''may'' be able to be reduced. I have tested the following code
in all known scenarios with success. It should replace the code I
originally posted (Sorry, but I do not know how to make the .diff files
yet - if I even have permissions for that kind of thing - new to all this)
{{{
if ( $referer = wp_get_original_referer() )
$location = $referer;
}}}
--
Ticket URL: <http://core.trac.wordpress.org/ticket/11870#comment:5>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list