function bodyStart($checkpost=true) {
        global $CFG;
        ob_start();
        // If we are in an iframe use different margins
?>
</head>
<body prefix="oer: http://oerschema.org">
<div id="body_container">
<script>
if (window!=window.top) {
    document.getElementById("body_container").className = "container_iframe";
} else {
    document.getElementById("body_container").className = "container";
}
</script>
<?php
        if ( $checkpost && count($_POST) > 0 ) {
            $dump = self::safe_var_dump($_POST);
            echo('<p style="color:red">Error - Unhandled POST request</p>');
            echo("\n<pre>\n");
            echo($dump);
            if ( count($_FILES) > 0 ) {
                $files = self::safe_var_dump($_FILES);
                echo($files);
            }
            echo("\n</pre>\n");
            error_log($dump);
            die_with_error_log("Unhandled POST request");
        }

        // Complain if this is a test key
        $key_key = $this->ltiParameter('key_key');
        if ( $key_key == '12345' &&
            strpos($CFG->wwwroot, '://localhost') === false ) {
            echo('<div style="background-color: orange; position: absolute; bottom: 5px; left: 5px;">');
            echo(_m('Test Key - Do not use for production'));
            echo('</div>');
        }

        $HEAD_CONTENT_SENT = true;

        $ob_output = ob_get_contents();
        ob_end_clean();
        if ( $this->buffer ) return $ob_output;
        echo($ob_output);
    }