[wp-trac] [WordPress Trac] #23446: Expose 'login_url' and 'admin_url' via XML-RPC
WordPress Trac
noreply at wordpress.org
Tue Feb 12 23:34:59 UTC 2013
#23446: Expose 'login_url' and 'admin_url' via XML-RPC
------------------------------+------------------------------
Reporter: daniloercoli | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: XML-RPC | Version: trunk
Severity: normal | Resolution:
Keywords: has-patch mobile |
------------------------------+------------------------------
Comment (by daniloercoli):
Replying to [comment:6 redsweater]:
> It does seem like adding the login and admin page URLs to that would be
reasonable. I still think given the dance you have to do to screen-scrape
the login page, it would be nice to just add a wp.login() method to get
the cookie, but this patch is obviously less work and probably a less
debatable change.
For the sake of precision it's just a POST to the login form with the URL
of the target page set as "redirect_to" parameter.
We are using this technique in 2 case:
- When we need to preview a draft|private|pending post. The value of the
redirect_to parameter is set with the permaLink of the post/page. - When
we need to access the Dashboard of the site. You can change the location
of /wp-admin/ and sometimes for security reason users did that.
If you are curious see:
http://ios.trac.wordpress.org/browser/trunk/WordPress/Classes/PostPreviewViewController.m#L205
--
Ticket URL: <http://core.trac.wordpress.org/ticket/23446#comment:7>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list