Пример #1
0
 /**
  * Parse the WordPress request.  If the pagename is 'openid_consumer', then the request
  * is an OpenID response and should be handled accordingly.
  *
  * @param WP $wp WP instance for the current request
  */
 function parse_request($wp)
 {
     openid_init();
     if ($wp->query_vars['pagename'] == 'openid_consumer') {
         WordPressOpenID_Logic::finish_openid($_REQUEST['action']);
     }
 }
Пример #2
0
 /**
  * Parse the WordPress request.  If the pagename is 'openid_consumer', then the request
  * is an OpenID response and should be handled accordingly.
  *
  * @param WP $wp WP instance for the current request
  */
 function parse_request($wp)
 {
     if (array_key_exists('openid_check_login', $_REQUEST)) {
         echo is_user_logged_in() ? 'true' : 'false';
         exit;
     }
     if (array_key_exists('openid_consumer', $_REQUEST) && $_REQUEST['action']) {
         openid_init();
         WordPressOpenID_Logic::finish_openid($_REQUEST['action']);
     }
 }