4,861
edits
Changes
Xsl
,cleanup
[http://www.w3.org/Style/XSL/ XSL] is a family of transformation languages which allows us to describe how files encoded in the XML standard are to be formatted or transformed.
We don't really iterate through the file, it is recursive. We retrieve data with XPath.
==Using XSL with gramps Gramps XML==
Some people use perl or python for retrieving some data from GEDCOM.
You may use XSL for this on Gramps XML, see [[media:Xpaths.gz|XPaths]]. Gramps XML is [http://gramps-project.org/xml/1.4.0/ documented] and coherent, we may use it for : * a database resume (output : HTML, XML, PS, PDF or SVG).* filtering some data and transforming result ([[Imagemedia:Ancestors.xsl.gz||||Ancestors.xsl]] , [[Imagemedia:Birthday.xsl.gz||||Birthday.xsl]] ).* a bridge between two open programs (GRAMPS Gramps <-> [[tellico|Tellico]]).* a web form.
==Examples==
* If you select GRAMPS Gramps object on XSL, and use this code with HTML output :
<img>
<xsl:attribute name="src">
</img>
:
then you will be able to display media objects on a HTML file. You may use all HTML codes or .css file for having what you want. Sample on a {{bug|2472}} bug-report.
* With XML, you will be able to make SVG. To generate a basic ancestors geographical map area with gramps Gramps coordinates.
For [[France]] area (dirty and quick test) :
You will get a layer according to specified dimensions on XSLT stylesheet.