Ticket #102 (closed defect: fixed)
DOCTYPE dropped with xhtml_transitional and layout
| Reported by: | zimbatm | Owned by: | somebody |
|---|---|---|---|
| Priority: | major | Milestone: | |
| Component: | camping.rb | Version: | 1.5 |
| Keywords: | xhtml | Cc: |
Description
When using a layout in which you use xhtml_transitional, the DOCTYPE is dropped. When you don't use the layout it works fine.
I've attached a unit-test that you can run if you have mosquito. Make a test folder in camping and run the test form camping project's root (otherwise mosquito will annoy you with a test.log file)
Result
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"><head><meta content="text/html; charset=utf-8" http-equiv="Content-Type"/><title>title</title></head><body><h1>With layout</h1></body></html>
Wanted result
<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"><head><meta content="text/html; charset=utf-8" http-equiv="Content-Type"/><title>title</title></head><body><h1>Without layout</h1></body></html>
