Here is the script i am currently working with. The htm file I am useing is linked to a .js file, a .css file, a .xsl file and severl .xml files. I am trying to create an interactive webpage that can browse thrue different database information organized on a table that displayes times and dates that can be changed by useing different buttons and keywords.
<script type="text/javascript" src="library.js"></script>
<script type="taxt/javascript">
var IE = window.activexobject ? true:false;
var MOZ = document.implementation.createdocument ? true: false;
var xmlFile; //Source XML document
var xsltFile = "lab.xsl";
var xmlDoc; //Source XML document
var xsltDoc; //XSLT style sheet document
function createXDoc(xFile, PID)
{
if (IE) {xFile=new ActiveXObject(getpid(DOMPID));
PID=new ActiveXObject(getpid(DOMPID));}
else (MOZ)
{xFile=document.implementation.createDocument("","",null);
PID=document.implementation.createDocument("","",null);}
}
function runTransform(xDoc, xsltDoc)
{
}
</script>
i have some instructions that came with the already created files.
1.)Within the head section, insert a script element linked to the library.js file. insert a second script element and declare the following global variables:
the IE and MOZ variables containing boolean values indicating whether the user's browser supports the IE or MOZ based browsers.
the xmlFile, xsltFile, xmlDoc, and xsltDoc variables storing the file names and document objects for the source document and XSLT style sheet documents. Set the initial value of the xsltFile variable to lab.xsl. Do not set initial values for the other variables.
2.)create a function called createXDoc(). The purpose of this function is to create and load an XML or XSLT file into a document object. the function has two parameters: xFile and PID. Write the function so that it creates and loads the document object under either IE or a MOZ browser. Return the document object created by the function.
3.)create a function named runTranform(), used to transform a source document and return the result document as a string of text. The function has two parameters named xDoc and xsltDoc. write the function so that it runs under IE or MOZ based browsers. have the function return the text string of the result document.
I think i have step one down good but i cant get step 2 and 3 if u have any info to help me with this i would greatly appreciate it. Thank you in advance!
<script type="text/javascript" src="library.js"></script>
<script type="taxt/javascript">
var IE = window.activexobject ? true:false;
var MOZ = document.implementation.createdocument ? true: false;
var xmlFile; //Source XML document
var xsltFile = "lab.xsl";
var xmlDoc; //Source XML document
var xsltDoc; //XSLT style sheet document
function createXDoc(xFile, PID)
{
if (IE) {xFile=new ActiveXObject(getpid(DOMPID));
PID=new ActiveXObject(getpid(DOMPID));}
else (MOZ)
{xFile=document.implementation.createDocument("","",null);
PID=document.implementation.createDocument("","",null);}
}
function runTransform(xDoc, xsltDoc)
{
}
</script>
i have some instructions that came with the already created files.
1.)Within the head section, insert a script element linked to the library.js file. insert a second script element and declare the following global variables:
the IE and MOZ variables containing boolean values indicating whether the user's browser supports the IE or MOZ based browsers.
the xmlFile, xsltFile, xmlDoc, and xsltDoc variables storing the file names and document objects for the source document and XSLT style sheet documents. Set the initial value of the xsltFile variable to lab.xsl. Do not set initial values for the other variables.
2.)create a function called createXDoc(). The purpose of this function is to create and load an XML or XSLT file into a document object. the function has two parameters: xFile and PID. Write the function so that it creates and loads the document object under either IE or a MOZ browser. Return the document object created by the function.
3.)create a function named runTranform(), used to transform a source document and return the result document as a string of text. The function has two parameters named xDoc and xsltDoc. write the function so that it runs under IE or MOZ based browsers. have the function return the text string of the result document.
I think i have step one down good but i cant get step 2 and 3 if u have any info to help me with this i would greatly appreciate it. Thank you in advance!