Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HTML5SourceAdapter ignores Doctype definition #15

Closed
hason opened this issue May 26, 2014 · 4 comments · Fixed by #17
Closed

HTML5SourceAdapter ignores Doctype definition #15

hason opened this issue May 26, 2014 · 4 comments · Fixed by #17
Assignees
Labels

Comments

@hason
Copy link
Contributor

hason commented May 26, 2014

<!DOCTYPE html>
<html>
  <head>
    <title>My Webpage</title>
  </head>
  <body>foo</body>
</html>

is transformed to

<html>
  <head>
    <title>My Webpage</title>
  </head>
  <body>foo</body>
</html>
@goetas goetas added the bug label May 26, 2014
@goetas goetas self-assigned this May 26, 2014
@goetas
Copy link
Owner

goetas commented May 26, 2014

See Masterminds/html5-php#42

@Stormcloud
Copy link

This appears to still be an issue. Is there a way to include the doctype in a template?

@goetas
Copy link
Owner

goetas commented Sep 21, 2017

@Stormcloud are you sure about it? https://github.com/goetas/twital/pull/17/files#diff-d19fc92e381ccbe7981b41585ed95dd9 is the test to ensure it. Can you share a not-working example?

@Stormcloud
Copy link

I have found the problem. If the doctype declaration is in lower case, it gets stripped from the output.
So <!DOCTYPE html> works, but <!doctype html> doesn't.
An error on my part, since upper case is the correct form.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants