emacs-pretest-bug
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Indentation bug in html-mode


From: Lennart Borgman (gmail)
Subject: Re: Indentation bug in html-mode
Date: Thu, 26 Apr 2007 10:55:06 +0200
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.3) Gecko/20070326 Thunderbird/2.0.0.0 Mnenhy/0.7.5.666

Stefan Monnier wrote:
The attached file is valid XHTML 1.1 but indents badly because of the < inte
<?php ... ?> part. I paste it here for simplicity too:
Hmm... does the patch below fix it for you?
If you put a "<?" inside your PHP code, it seems it would still be valid
XML, but indentation will probably get confused.
It fixes the last two lines (</body> and </html>), but not the </div> line.
The additional patch below should fix that, provided Emacs is in XHTML mode
(rather than HTML mode).  If I understand the HTML docs properly your
example code is not valid in HTML because the < is not allowed inside
<?php ...>.


Thanks, indeed that did the trick.

I guess you with XHTML mode mean html-mode + XHTML DTD? How do I get
html-mode to follow the XHTML DTD? In the circumstances I am going to use it
sometimes there are no proper header part with DTD spec.

No, I mean that Emacs is using html-mode with sgml-xml-mode set to t (this
is normally reflected in the mode-line as "XHTML").

It would be very nice if these bug fixes were installed before the release.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]