Connecting Tech Pros Worldwide Help | Site Map

Creating sub xsl files and calling from main xsl file

Newbie
 
Join Date: Aug 2008
Posts: 1
#1: Aug 7 '08
I am attempting to break my templates down from 1 main xsl file into smaller files. Then I want to call them from a main xsl file. I started to look. I have found xsl:include and xsl:import. Also, not sure to use apply-templates or call-templates.


Trying to find good examples on both w/ the main file and source file, but have it a road block. Does anyone have ideas on this or good xsl sites that I can refer too.



~thanks!
Moderator
 
Join Date: Mar 2006
Posts: 1,103
#2: Aug 8 '08

re: Creating sub xsl files and calling from main xsl file


In general, if you can use apply-templates instead of call-templates, do it.

Call-template should be used when you have a particular function that you want to run. eg, if you wanted to search/replace on a set of values.
Reply