Altova Mailing List Archives

Re: transfer xml content to new window

From: outzen@-----.----.-- (----- ------)
Date: 2/17/2004 10:07:00 AM
Well - it wasnt so difficult at all - just had to put in a
"target=%windowname%" in the "<a>" tag. (basic htm .. urghh)

On Tue, 17 Feb 2004 08:34:46 GMT, outzen@p... (Jakob Outzen)

>Its probably very simple, however having difficulties with forcing
>below script to open in another window, when user hits the "<A>" tag !
>Basicly the page is loaded in a top frame (frameset consists of a top
>and bottom frame), and I would like it to open the "vis_indlaeg.asp"
>in the bottom frame.
><?xml version="1.0" encoding="utf-8"?>
><xsl:stylesheet xmlns:xsl=""
>version="1.0"><xsl:output method="html" encoding="utf-8"/>
>	<xsl:template match="/">
><LINK REL="stylesheet" HREF="hierarki.css" TYPE="text/css"/>		
><SCRIPT language="JavaScript" FOR="eSwapper" event="onclick">
>	event.cancelBubble = true;		
>	oDiv = event.srcElement.parentElement;
>	if (!oDiv.all.item("eIndlaeg")) return;
>	var strValue = (oDiv.children[3].style.display == "none" ?
>"block" : "none");
>	oDiv.children[0].src = (strValue == "none" ? "plus.gif" :
>	for (var i=3; i!=oDiv.children.length; i++) {
>	oDiv.children[i].style.display = strValue;
>			}
>	<BODY>
><SPAN CLASS="overskrift">Lys og Lampe AS's forslagkasse</SPAN><BR/>
><SPAN CLASS="tekst">Some text </SPAN>
>			<BR/><BR/>		
>	<xsl:apply-templates select="/document/indlaeg" />	
>			<BR/><BR/>
><SPAN CLASS="tekst">Some text </SPAN>
>		</BODY></HTML>
>	</xsl:template>
>	<xsl:template match="indlaeg">
><DIV Id="eIndlaeg">
><xsl:attribute name="class">indryk<xsl:value-of
>select="count(ancestor::*)" /></xsl:attribute>			
><IMG SRC="minus.gif" ID="eSwapper" />
>	<A>
><xsl:attribute name="href">vis_indlaeg.asp?indlaegid=<xsl:value-of
>select="@id" /></xsl:attribute>
><xsl:value-of select="overskrift" />
>	</A>
><SPAN CLASS="info">[<xsl:value-of select="oprettetaf" />,
><xsl:value-of select="tidspunkt" /> ]</SPAN>	
><xsl:apply-templates select="indlaeg" />
>	</DIV>
>	</xsl:template>	
>var oSource = Server.CreateObject("MSXML2.DOMDocument.3.0");
>oSource.async = false;
>var oStylesheet = Server.CreateObject("MSXML2.DOMDocument.3.0");
>oStylesheet.async = false;
>var oVisElement = oSource.createNode (1, "visindlaeg", "");
>oVisElement.text = Request("indlaegid");
>oSource.transformNodeToObject (oStylesheet, Response);


These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.