[xsl] "redirect" xml-stylesheet processing instruction

Subject: [xsl] "redirect" xml-stylesheet processing instruction
From: Hermann Stamm-Wilbrandt <STAMMW@xxxxxxxxxx>
Date: Mon, 12 Nov 2012 19:47:59 +0100
I did search for "redirect" in xsl-list archive and did not find something
similar to this among the 20 hits found.


In a previous posting on this forum I made use of /html/head/meta/@
http-equiv
of value "refresh" to provide pure XML animations:
http://www.biglist.com/lists/lists.mulberrytech.com/xsl-list/archives/200907/msg00180.html

In that posting the redirect-URL was a static string.


In below posting stylesheet "redirect.gmap.xsl" is used in a xml-stylesheet
processing-instruction, passing the URL "where to redirect to" as query
arg:
https://www.ibm.com/developerworks/mydeveloperworks/blogs/HermannSW/entry/gpxs2kml_xsl_convert_multiple_gmap_pedometer_com_routes_to_kml9

Passing the URL (which is a "self reference") seems to be necessary as from
previous threads on xsl-list it seems to be clear that a (XSLT 1.0)
stylesheet is not able to determine the URL of its XML input.

Anyway, this method may be useful in contexts different to forward KML
files
to maps.google.com KML viewer or redirecting only Firefox to a static HTML
page as in this posting by "redirect.ff.xsl":
https://www.ibm.com/developerworks/mydeveloperworks/blogs/HermannSW/entry/google_maps_api_and_xslt3


Mit besten Gruessen / Best wishes,

Hermann Stamm-Wilbrandt
Level 3 support for XML Compiler team and Fixpack team lead
WebSphere DataPower SOA Appliances
https://www.ibm.com/developerworks/mydeveloperworks/blogs/HermannSW/
https://twitter.com/#!/HermannSW/
----------------------------------------------------------------------
IBM Deutschland Research & Development GmbH
Vorsitzende des Aufsichtsrats: Martina Koederitz
Geschaeftsfuehrung: Dirk Wittkopp
Sitz der Gesellschaft: Boeblingen
Registergericht: Amtsgericht Stuttgart, HRB 243294

Current Thread