Skip to content

Commit

Permalink
MDL-30921 output: Added the main role to the main content area
Browse files Browse the repository at this point in the history
  • Loading branch information
Sam Hemelryk committed Nov 1, 2012
1 parent 5c4581f commit 537ba51
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion lib/outputrenderers.php
Expand Up @@ -492,7 +492,13 @@ public function standard_footer_html() {
* @return string HTML fragment.
*/
public function main_content() {
return $this->unique_main_content_token;
// This is here because it is the only place we can inject the "main" role over the entire main content area
// without requiring all theme's to manually do it, and without creating yet another thing people need to
// remember in the theme.
// This is an unfortunate hack. DO NO EVER add anything more here.
// DO NOT add classes.
// DO NOT add an id.
return '<div role="main">'.$this->unique_main_content_token.'</div>';
}

/**
Expand Down

0 comments on commit 537ba51

Please sign in to comment.