Date: Fri, 11 Dec 2009 21:49:42 +0100 From: cpghost <cpghost@cordula.ws> To: Aryeh Friedman <aryeh.friedman@gmail.com> Cc: FreeBSD Mailing List <freebsd-questions@freebsd.org> Subject: Re: OT: XML newbie Message-ID: <20091211204941.GA54396@phenom.cordula.ws> In-Reply-To: <bef9a7920912102250u2dd176a2m280326d0c7b3c2fe@mail.gmail.com> References: <bef9a7920912102250u2dd176a2m280326d0c7b3c2fe@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, Dec 11, 2009 at 01:50:40AM -0500, Aryeh Friedman wrote: > I am a relative XML newbie (i.e. our backend does spit out some XML I > wrote but it just slapped together with no knowledge of the > underlaying structure of XML)... Now I am going back and actually > learning XML... our main application is to insert XML directly into > XHTML documents and use either CSS or XSLT (don't know enough to pick > yet) to style them without resorting to javascript... I'm using xsltproc from the port textproc/libxslt to apply custom XSLT style sheets to XML files, resulting in XHTML output. Works great, and is super fast. xsltproc also understands the xmlns:exsl extensions, which means that it can generate multiple output files from a single XML input file, using the exsl:document element (very useful in the context of XHTML generation where you need to create multiple interlinked pages). > Now my question what is a good/reasonable set of command line tools > for working with/debugging/testing all this in such a way I do not > need to rely on the browser... specifically what types (and specific > ones if there is a preference) tools do I need and are there any > recommended procedures for dealing with XML from the command line.... > in the future we may want to also do Java parsing of XML but that > seems to be well handled already in the JDK (1.6) API.... thanks in > advance You can test the XML prior to applying XSLT, using something like xmllint from textproc/libxml2. xmllint is also particularly useful, if your main XML file inputs (with xi:include) other XML files (use the option --xinclude), and it can verify DTD as well. I also use www/linklint on the set of generated XHTML files to check for broken links etc..., though I guess it could be automated at the XML (DTD?) level too. Regards, -cpghost -- Cordula's Web. http://www.cordula.ws/
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20091211204941.GA54396>