diff options
author | Angie Byron <webchick@24967.no-reply.drupal.org> | 2010-05-05 07:00:49 +0000 |
---|---|---|
committer | Angie Byron <webchick@24967.no-reply.drupal.org> | 2010-05-05 07:00:49 +0000 |
commit | e0be60f6128709f944f1aa56c92b3342006761b9 (patch) | |
tree | 95bb37fb9548a3636be4e12a115ec4ef6039cf93 /modules/openid | |
parent | 57d44a6cf95445646965863e0366674e64f8de87 (diff) | |
download | brdo-e0be60f6128709f944f1aa56c92b3342006761b9.tar.gz brdo-e0be60f6128709f944f1aa56c92b3342006761b9.tar.bz2 |
#730598 by dirtabulous, Heine: Fixed OpenID redirect form is not valid HTML.
Diffstat (limited to 'modules/openid')
-rw-r--r-- | modules/openid/openid.inc | 19 |
1 files changed, 14 insertions, 5 deletions
diff --git a/modules/openid/openid.inc b/modules/openid/openid.inc index 2c17d2c90..96c80269d 100644 --- a/modules/openid/openid.inc +++ b/modules/openid/openid.inc @@ -89,11 +89,20 @@ function openid_redirect_http($url, $message) { * Creates a js auto-submit redirect for (for the 2.x protocol) */ function openid_redirect($url, $message) { - $output = '<html><head><title>' . t('OpenID redirect') . "</title></head>\n<body>"; + global $language; + + $output = '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">' . "\n"; + $output .= '<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="' . $language->language . '" lang="' . $language->language . '">' . "\n"; + $output .= "<head>\n"; + $output .= "<meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n"; + $output .= "<title>" . t('OpenID redirect') . "</title>\n"; + $output .= "</head>\n"; + $output .= "<body>\n"; $elements = drupal_get_form('openid_redirect_form', $url, $message); $output .= drupal_render($elements); - $output .= '<script type="text/javascript">document.getElementById("openid-redirect-form").submit();</script>'; - $output .= "</body></html>\n"; + $output .= '<script type="text/javascript">document.getElementById("openid-redirect-form").submit();</script>' . "\n"; + $output .= "</body>\n"; + $output .= "</html>\n"; print $output; drupal_exit(); @@ -112,8 +121,8 @@ function openid_redirect_form($form, &$form_state, $url, $message) { $form['actions'] = array('#type' => 'actions'); $form['actions']['submit'] = array( '#type' => 'submit', - '#prefix' => '<noscript>', - '#suffix' => '</noscript>', + '#prefix' => '<noscript><div>', + '#suffix' => '</div></noscript>', '#value' => t('Send'), ); |