I'm using this function below in Wordpress:
function wpstudio_doctype() {
$content = '<!DOCTYPE html>' . "\n";
$content .= '<html ' . language_attributes() . '>';
echo apply_filters( 'wpstudio_doctype', $content );
}
Problem is that the function displays $content above the <!DOCTYPE html> tag, instead of adding the string inside of the HTML tag.
What am I doing wrong here?