help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: New version of nXhtml available


From: Lennart Borgman (gmail)
Subject: Re: New version of nXhtml available
Date: Fri, 07 Mar 2008 18:24:50 +0100
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.9) Gecko/20071031 Thunderbird/2.0.0.9 Mnenhy/0.7.5.666

Richard G Riley wrote:
Richard G Riley <rileyrgdev@gmail.com> writes:

"Lennart Borgman (gmail)" <lennart.borgman@gmail.com> writes:

Just uploaded a new version of nXhtml, see

  http://www.emacswiki.org/cgi-bin/wiki/NxhtmlMode

There are rather big changes in this release.
I created a new file, text.php,

<div src="hello"></div>
<img alt="angry" src="hello.gif"/>


and both div and img are underlined I can do no completion at any
point. How to set this up to work? I tried various validation
schemas. Maybe I am missing something?

Hi Richard,

Yes, but I can see that you have found it: Fictive XHTML validation headers. They are supposed to tell the XHTML parser (from nxml-mode) the state beginning parsing state.

As you surely know now they are in the menus under

  nXhtml
    Completion and Validation
      Validation helpers (for php etc)

Can you run through just what sequence of options I must select to make
this work (emacs 22).

I think I might be getting confused between the schema settings under
xml and the nxhtml completion.

But if you could run through from A to Z on getting completion working I
would be grateful.

It is just that validation header which you need in a buffer where there is no or just a partial "document header".

Multiple major mode is working. if I add some embedded php it
switches. But I'm more interested in just getting basic nxhtml
completion working for a start.

Should everything be done from the nxhtml menu? Or a combination of the
xml and the nxhtml menu? The docs here:

http://ourcomments.org/Emacs/nXhtml/doc/nxhtml.html

are a little vague.

Most things you need are in the nXhtml menu. You should not need to do things like "Set Schema" from the XML menu. However if you PHP code is just using <?php ... ?> tags (and does not do those things inside an attribute or as part of an opening tag) then "First Error"/"Next Error" can of course be useful.

If you think the docs can be improved then maybe you have some suggestion?

Possibly I have old "settings" files left lying around from the old
version? Should I delete my schemas.xml file?

You should not need any such file just to edit PHP. Everything needed should be there with nXhtml.

Any help appreciated.

Just a little more info : I can see the fictive validation header. But
the actual php buffer appears not to be validated with it. If I remove
the 2 lines above and then select completion the first option is
<html

even though I see that already in the fictive buffer. The only
conclusion  I can come to is that its not using the fictive visible
validation header for some reason.

That does not happen for me here. It could be a bug. (A difficult one. The parser could be in a bad state.)

Could you just close the file and reopen it? Then add the validation header again.

Does it work for you now? Otherwise please send me more detailed information. Exactly what do you do etc.




reply via email to

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