2 ms·
Alternate interpretation: w3c's XHTML was machine understandable. It took great care to introduce rigid and reusable semantics. You could spider the web and di
by echelon 4y ago
Alternate interpretation:
w3c's XHTML was machine understandable. It took great care to introduce rigid and reusable semantics. You could spider the web and directly extract facts without ML or heuristics. It spiritually brought HTML closer to RSS and RDF, and there would have been a lot you could do with that.
Google didn't want anything to do with that future. Search is their moat. They pushed a format that is easy for humans to author, tolerably messy, and knowledgeless for machines. If the format was difficult to extract knowledge from in a scalable and reusable way, Google could keep their search kingdom.
XHTML was a ladder rung into the semantic web. A distributed knowledge graph that could be mined, remixed, and extended with little effort. It was marginally harder to author (the mimetype issue was ridiculous), but extending it was low hanging fruit.
This isn't necessarily how it went down, but the incentives do align. I do think we'd have more automation in the world today if we'd have adopted XHTML.
Now with AI/ML and NLP I think we'll get to this kind of web without a format to rigidly specify semantics. I still have to think that the ideas of semantic web and P2P could have delivered decades ago if Google and Facebook hadn't overwhelmingly pushed the envelope on centralized resources.
- zozbot234 4y agoHTML5 can be auto-translated into an XML surface syntax. You aren't losing anything compared to the old XHTML, though only the XML syntax can include content from other XML namespaces. Google even cooperates with other search engines in promoting unified formats to "extract knowledge from in a scalable and reusable way", namely the schema.org standards.
- echelon 4y agoXHTML treated schemas as a first class order of business, though. It would require people to use extra effort to author a table of "address information" (or whatever). Maybe that would not have happened, but the format also suggested the building of reusable components, browser integrations for semantic understanding, and much more. The world it alluded to was much brighter for machine understanding and reusability.
- Devasta 4y agoData served in a tree structure and then rendered with client side templating with the ability to create custom elements... those crazy W3C eggheads in their ivory tower, why did they think anyone would want that? /s
- schemescape 4y agoIs the “can be translated into XML” part of the HTML5 spec? That would be interesting to me, and I wasn’t aware of it until your comment. Edit: sounds like it’s not a thing: > The DOM, the HTML syntax, and the XML syntax cannot all represent the same content. https://html.spec.whatwg.org/multipage/introduction.html#html-vs-xhtml https://html.spec.whatwg.org/multipage/introduction.html#htm...
- domenicd 4y agoThe non-translatable features are extremely niche, though. To continue the quote: > For example, namespaces cannot be represented using the HTML syntax, but they are supported in the DOM and in the XML syntax. Similarly, documents that use the noscript feature can be represented using the HTML syntax, but cannot be represented with the DOM or in the XML syntax. Comments that contain the string "-->" can only be represented in the DOM, not in the HTML and XML syntaxes. I.e. the big thing you'd fail to capture when doing an automated HTML -> parsed DOM -> XML trip is noscript tags. No big loss. Others I can remember are similarly tiny, e.g. some issues around textarea elements containing only newlines as their initial contents. Some discussion at https://html.spec.whatwg.org/multipage/parsing.html#parsing https://html.spec.whatwg.org/multipage/parsing.html#parsing Ctrl+F "roundtrip", although note that most of that is actually about what happens if you construct weird DOMs with JS and try to do a DOM -> serialized HTML -> reparsed DOM roundtrip. I think it's pretty safe to say in general that the procedure of "parse HTML to DOM, serialize to XML" will preserve everything interesting about a document. Especially if that document is already valid HTML.
- schemescape 4y agoAh, I thought those were just a couple of examples from a much larger set.
- gsnedders 4y agoPedantically, yes, there is a fair bit larger set, but they really only get more and more esoteric (and often things that are allowed within the HTML syntax but where the content would be non-conforming). For example: You can have an element called "foo:bar" in HTML, but you can't in XML-with-Namespaces-in-XML; likewise, you can have an element called "a\u0300" in HTML, but you can't in XML (and the set of possible element names is even more different if you're looking at an implementation of XML 1.0 4th Edition, which most are, rather than the much later 5th edition). You can't have a comment that contains "--" or ends with "-" in XML. (This is potentially the thing that comes up most often in real world content: people like doing <!------ DON'T TOUCH THIS ------>, which in HTML produces a comment whose value is "---- DON'T TOUCH THIS ----", which you cannot represent in XML.)
- tbrownaw 4y ago> XHTML was a ladder rung into the semantic web. A distributed knowledge graph that could be mined, remixed, and extended with little effort. The first attempt at that "knowledge graph" thing was the "keywords" meta tag. Its failure should be taken as instructive regarding the difficulty level of the project as a whole. > It was marginally harder to author (the mimetype issue was ridiculous), but extending it was low hanging fruit. Silly me, I thought it was more about mandatory strictness vs user-generated content, rather than what mime-type the server had to label it as.
- bawolff 4y ago> The first attempt at that "knowledge graph" thing was the "keywords" meta tag. Its failure should be taken as instructive regarding the difficulty level of the project as a whole. Knowledge graphs are basically just semantic networks, which arguably date back to 1956 (or 300 depending on how you define things)
- Jasper_ 4y ago> w3c's XHTML was machine understandable. It took great care to introduce rigid and reusable semantics. You could spider the web and directly extract facts without ML or heuristics. It did absolutely none of this. It was an presentation layer built on top of XML, and it did not really touch semantics at all. The W3C's proposed direction for the future of the web was for everybody to write data as XML, and then apply XSLT transforms to build XHTML as the structural presentation layer, with CSS providing styling information on top. XHTML added very few additional semantics, other than loose concepts that were worse than useless. > It was marginally harder to author (the mimetype issue was ridiculous), but extending it was low hanging fruit. It was difficult to author (there were days you could run random websites through the "XHTML Validator", and despite them trying, find plenty of errors). The mimetype issue was that Internet Explorer would not recognize a proper XHTML mimetype, while other browsers wouldn't turn on XHTML mode when the mimetype was text/html. https://webkit.org/blog/68/understanding-html-xml-and-xhtml/ https://webkit.org/blog/68/understanding-html-xml-and-xhtml/ -- this blog post was written as XHTML's last dying breath, and I think was the nail in the coffin for it.
- Devasta 4y agoIt is amazing to look back at arguments against XHTML and to realise just how awful they really were.
- tannhaeuser 4y agoW3C's XML (and also semantic web stuff) is an excellent example of what not to do as standardization body. XML may be important for enterprises, but what was achieved for the web except a decade-long meta discussing, resulting into HTML taken away (or back if you will) by browser vendors after years of stagnation? There was zero need for XML; recall XML is just a proper subset of SGML by its original developers, which was used to specify HTML until version 4. And even today, SGML is the only game in town to parse HTML (including version 5, up to minor trivialities) based on an international standard, whereas Hickson's/WHATWG's procedural parsing spec has become unmaintainable and isn't covered by a test suite, precisely because it doesn't follow a formal model, but started from a prose description of what an SGML parser does but lost track. Not a great outcome for a markup language used daily by billions of people; especially since HTML the markup language hasn't really changed for a very long time, whereas everything around it (CSS, JS) had to change drastically to make up for HTML's stagnation and first W3C's, then WHATWG's fuckups.
- bawolff 4y agoXML may have failed as a syntax for HTML, but it was enormously succesful in its own right. W3C has lots of failures and bad standards. I don't think the base XML spec was one of them, even if i think JSON is better for most usecases.
- Kwpolska 4y agoIt was successful in the 2000s, but then everyone figure out it’s pointless, and all data exchange in software written in the past decade is in JSON or possibly protobuf.
- bawolff 4y agoAll things have a time. XML was succesful in its. That it was eventually taken over by competitors doesn't really detract from it being hugely succesful in its time.