ajaxlib: MDL-19915 skip links need to be in a div for XHTML strict.

Refine Sam's solution.
This commit is contained in:
tjhunt 2009-07-23 05:39:41 +00:00
parent f0b529e0a9
commit ac63efae6d

View File

@ -427,7 +427,7 @@ class page_requirements_manager {
* @return string the HTML code to go at the start of the <body> tag.
*/
public function get_top_of_body_code() {
$output = $this->get_linked_resources_code(self::WHEN_TOP_OF_BODY);
$output = '<div class="skiplinks">' . $this->get_linked_resources_code(self::WHEN_TOP_OF_BODY) . '</div>';
$js = "document.body.className += ' jsenabled';\n";
$js .= $this->get_javascript_code(self::WHEN_TOP_OF_BODY);
$output .= ajax_generate_script_tag($js);
@ -849,7 +849,7 @@ class required_skip_link extends linked_requirement {
}
public function get_html() {
return '<div><a class="skip" href="#' . $this->url . '">' . $this->linktext . "</a></div>\n";
return '<a class="skip" href="#' . $this->url . '">' . $this->linktext . "</a>\n";
}
}