Proyectos de Subversion Moodle

Rev

Rev 1307 | Rev 1313 | Ir a la última revisión | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 1307 Rev 1312
Línea 1375... Línea 1375...
1375
     *
1375
     *
1376
     * @return string HTML fragment.
1376
     * @return string HTML fragment.
1377
     */
1377
     */
1378
    public function main_content()
1378
    public function main_content()
1379
    {
1379
    {
1380
        // This is here because it is the only place we can inject the "main" role over the entire main content area
1380
        $this->page->set_state(moodle_page::STATE_IN_BODY);
1381
        // without requiring all theme's to manually do it, and without creating yet another thing people need to
-
 
1382
        // remember in the theme.
1381
        ob_start();
1383
        // This is an unfortunate hack. DO NO EVER add anything more here.
1382
        $this->page->get_renderer('core')->render_page_content();
1384
        // DO NOT add classes.
1383
        return ob_get_clean();
1385
        // DO NOT add an id.
-
 
1386
        return '<div class="main-content" role="main">' . $this->unique_main_content_token . '</div>';
-
 
1387
    }
1384
    }
Línea 1388... Línea 1385...
1388
 
1385
 
1389
    /**
1386
    /**
1390
     * Outputs a heading
1387
     * Outputs a heading