?
Solved

How do I include the same html code in all of my xsl sheets when they transform to html docs?

Posted on 2005-05-14
1
Medium Priority
?
205 Views
Last Modified: 2013-12-25
This is basically the same question I've been asking and researching for 2 weeks and I know it can't be this hard.
This is my first XML project and I am learning as I go.  A little knowledge ... well you know.

I have one big XML doc.  I use a script to select one of many xsl stylesheets and using transformNode, I create  different html docs.  It works great. I even use SelectSingleNode so that I am only applying the stylesheet to the node that I am interested in.

Anyway, here's the problem.  There is a lot of html formatting going on including a top border and a left border with a lot of links.  They are hard coded into each and every xsl doc I am using (19 going on 50).  I would like to find a way to do the borders once and add the code to the xsl doc before it gets transformed. I have tried <xsl:import>, <xsl:include>,  frames, shared borders and nothing works. I'm sure there is something obvious that I just haven't stumbled onto yet.  Or maybe I'm just using these badly.

Is there a solution out there that I am overlooking? I'm assigning 500 points because it's time to get it resolved.

Please help.
0
Comment
Question by:racing_chicken
1 Comment
 
LVL 53

Accepted Solution

by:
COBOLdinosaur earned 2000 total points
ID: 14003906
If I am reading your Q right <xsl:include href="uri" /> should work.  It must be a child node of either <xsl:stylesheet> or <xsl:transform>

Do you have the correct parent child relationship?

If you are not already using it you may find this a useful reference:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/xmlsdk/html/79c78508-c9d0-423a-a00f-672e855de401.asp


Cd&
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

There’s a good reason for why it’s called a homepage – it closely resembles that of a physical house and the only real difference is that it’s online. Your website’s homepage is where people come to visit you. It’s the family room of your website wh…
Today, the web development industry is booming, and many people consider it to be their vocation. The question you may be asking yourself is – how do I become a web developer?
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…
The is a quite short video tutorial. In this video, I'm going to show you how to create self-host WordPress blog with free hosting service.
Suggested Courses
Course of the Month14 days, 11 hours left to enroll

840 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question