Slashdot Mirror


Mozilla + CSS + XML = Structured, Formatted Content

Saqib Ali writes "Publishing XML content on the web requires some heavy processing on the server. There are many publishing framework (AxKit, Cocoon, etc) available in the market. However they are very CPU intensive. Apple's Internet Developer has a article on how to use CSS along with your XML content to render the formatted content in the Mozilla Web browser. It is very interesting read, especially for people who want to start creating content in XML, but don't want to invest in a expensive processing server/application. They have a nice example of RSS feed (XML) formatted for publishing in the browser."

3 of 28 comments (clear)

  1. Re:*ahem* by DarkVein · · Score: 5, Insightful

    Not off topic in the least. Slashdot uses antiquated HTML and CSS. It has no reason to use javascript on the front page. It uses tables for layout, when paragraphs would serve, and <img> when background-image would serve. Contextual markup would make the page more accessible to every sort of device, including PDAs and cellphones. Slashdot should move to XHTML 1.1, which is an application of XML.

    There's more, but I thought "for slashdot?" would be quite succinct. If nothing else, slashdot could cut its bandwidth usage in half, and serve the exact same HTML for the "light" and full-bloat^Hn themes.

    --

    I'm as mimsy as the next borogove but your mome raths are completely outgrabe.

  2. Re:XSLT? by vbweenie · · Score: 4, Informative

    One typical use of XSLT is as a translator between marked-up data (XML) exported from somewhere and a marked-up hypertext document (HTML) presenting that data or a subset of it for the web.

    Neither the XML nor the HTML will necessarily contain any formatting information beyond HTML's fairly basic set of tags, so you might still need CSS to finesse the layout and appearance.

    An alternative is to translate from XML via XSLT into XSL:FO, and from there into PDF (using Apache's FOP). This is a still-maturing technology, however, and it's a bit verbose for my liking - but you can say that about most of the X* family...

    --
    Experience is a hard school, but fools will learn no other.
  3. Re:Bah. Boring. What's NEEDED is this: by Felipe+Hoffa · · Score: 4, Informative

    Maybe gSOAP is the answer for your needs.

    It is a library for C and C++ that generates codes for using (as a client) or providing (as a service) web services using the SOAP standard (based on XML).

    If you give gSOAP a header file with the methods and structures of your code, it will generate all the needed methods and XML descriptors without giving you much trouble. From there it will be easy to serialize all your data in and out, and you won't have to care about the details of the XMLs. As an added benefit you will be able to share your data with software written in several other languages.

    Fh