Log in   Register a New Account

Accessify Forum - Discuss Website Accessibility

New to the forum?

Only an email address is required.

Register Here

Already registered? Log In

Need a WYSIWYG for custom CMS.

  • Reply to topic
  • Post new topic
Reply with quote Thinking of building our own custom CMS for work. Can I ask why all decent WYSIWYG editors only output XHTML and not HTML strict?

Can I also ask why no WYSIWYG editors can handle block level styling and are there plans for XStandard to be able to do this?

Johan De Silva / Portfolio
Reply with quote The output of XHTML from these tools is because of hype. There used to be a widespread view that XHTML was somehow better than HTML.

As for block-level styling, projects I've worked on have usually haven't had that available as a default feature. The need for it is usually rare, so the editor components only permit hand-authoring it in the HTML source view.

IIRC, there was a system where you could add class names to the interface. Can't find a link to it. I did remember Alastair Campbell's WYSIWYG category. In particular, his Importing CSS article details how class could be incorporated into editors.
Reply with quote
Quote:
The output of XHTML from these tools is because of hype.

Not at all. The output of XStandard is XML in the XHTML dictionary. The reason why XStandard generates XML output is because many users process the output from the editor using XML tools before the output (content) is merged with a Web page template in order to generate the final Web page. For example, please see Advanced image management article.

The editor also lets users customize the Preview and Screen Reader Preview features via XSLT. This would not be possible if the output was not XML.

And some CMS vendors needs to process content en-masse as a batch process to make changes. For example, if they need to change:

Code:
<h3 class="class-name">


to

Code:
<h2 class="new-class-name">


The only reliable way to do this for thousands of documents is to use XSLT or XML DOM parser. Using regular expressions can be risky and complicated to write if the markup sometimes contains other attributes such as "id" and "title".

Vlad Alexander
XStandard Development Team
http://xstandard.com
Reply with quote There's no need to send HTML-with-an-XHTML-DOCTYPE to the browser. You could transform the XML into HTML before final transmission. XSLT has an HTML output mode, for example.

More radically, all the XML parsing could be replaced by HTML parsing. This would allow all the templates and content to be stored using the same HTML as would be transmitted. The same transformations would be possible; you'd just have an HTML parser creating the memory structure which gets transformed instead of an XML parser.

I fully agree with RegEx parsing being a terrible idea, though!
Reply with quote
Quote:
There's no need to send HTML-with-an-XHTML-DOCTYPE to the browser

I think this would fall outside the scope of this discussion. The discussion started with the question why decent WYSIWYG editors generate XHTML. And my response is that markup generated by the WYSIWYG editor (for CMS) needs to be easily parsable using off-the-shelf tools. XML is the best choice because all development environments have XML parsers and you have such variety like DOM XML parser, XSLT and SAX.

Quote:
all the XML parsing could be replaced by HTML parsing.

Internally a tool can use HTML parsing but CMS vendors/app developers need to be able to use parsing tools that cannot be replaced by HTML parsers. HTML parsers, which are still exotic tools are based on DOM (I think?), so they cannot replace two wonderful technologies such as XSLT and SAX.

Vlad Alexander
XStandard Development Team
http://xstandard.com
Reply with quote
Vlad Alexander wrote:
Cerbera wrote:
There's no need to send HTML-with-an-XHTML-DOCTYPE to the browser
I think this would fall outside the scope of this discussion.
Then why continue with a long paragraph discussing it? Smile

Vlad Alexander wrote:
The discussion started with the question why decent WYSIWYG editors generate XHTML.
Which is the same as asking why they transmit HTML-with-an-XHTML-DOCTYPE to the browser. It is the whole point of the discussion.

Vlad Alexander wrote:
And my response is that markup generated by the WYSIWYG editor (for CMS) needs to be easily parsable using off-the-shelf tools. XML is the best choice because all development environments have XML parsers and you have such variety like DOM XML parser, XSLT and SAX.
All of that happens before transmission to the browser. So there's still no reason to transmit a mish-mash of markup to the browser. The CMS can still store and process everything as XML, then transform the page into HTML and transmit it to the browser.

Vlad Alexander wrote:
Cerbera wrote:
all the XML parsing could be replaced by HTML parsing.
HTML parsers, which are still exotic tools are based on DOM (I think?), so they cannot replace two wonderful technologies such as XSLT and SAX.
TagSoup is a SAX-compliant HTML parser, according to its homepage. Quite a famous one, too. I imagine good XSLT products can accept a suitable data type sent from an HTML parser, run the transformation on that, then return the result?

Even if you use XML for your storage, the XSLT specification says it can generate HTML. So there's still no reason to transmit XHTML as text/html: just use the HTML mode.
Reply with quote
Cerbera wrote:
Vlad Alexander wrote:
Cerbera wrote:
There's no need to send HTML-with-an-XHTML-DOCTYPE to the browser
I think this would fall outside the scope of this discussion.
Then why continue with a long paragraph discussing it? Smile



Rolling Eyes see productive online discussions

Display posts from previous:   

All times are GMT

  • Reply to topic
  • Post new topic