XML Editor
Sign up for a WebBoard account Sign Up Keyword Search Search More Options... Options
Chat Rooms Chat Help Help News News Log in to WebBoard Log in Not Logged in
Show tree view Topic
Topic Page 1 2 3 4 5 6 7 8 9 Go to previous topicPrev TopicGo to next topicNext Topic
Postnext
Justin TierneySubject: Newbie Help Needed (XSL Support Needed) (",)
Author: Justin Tierney
Date: 09 Apr 2006 03:39 AM
Hi All,

Let me start by saying, i am a COMPLETE newbie to both this program and XML.

First off, Program is fantastic, just got my evaluation (enterprise edition) and it is fantastic.

I have made a full XSL template? for the XML provided by my clans server host.

Now, I have made it i have included the output below.

The question (Im sure you'll find it incredibly dumb) but i wanted to know how to Display XSL + XML on a .asp page for my website.

I wanted to show the information on a .asp page.

Also the XML file is on a different website. not my own.

Basically

XML Hosted at: http://clanforge.multiplay.co.uk/public/servers.pl?event=Online;opt=ServerXml;serverid=4940;fake=server.xml

XSL, XML Wanted Displayed At: www.dirtyratsclan.com

A fast reply would be greatly appreciated, and a resolution to my problem.

The XSL Is below.

<?xml version='1.0' encoding='utf-8'?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:NonHtml="http://www.progress.com/StylusStudio/NonHtml" exclude-result-prefixes="NonHtml">
<xsl:output method="html"/>
<xsl:template match="/">
<html>
<body style="background-color: #383838">
<p dir="ltr" align="left" style="margin-right: 0px">
<table width="440" border="0" style="; background-color: #444444">
<tbody>
<tr>
<td width="5%">
<img hspace="0" src="http://www.dirtyratsclan.com/images/blocks.gif" align="absBottom" border="0"/>
</td>
<td width="55%">
<font face="Arial" color="#2f9ecb" size="2">
<strong>Server Details</strong>
</font>
</td>
</tr>
</tbody>
</table>
<table width="440" style="; background-color: #383838">
<tbody>
<tr>
<td width="120">
<font face="Arial" color="#2f9ecb" size="2">
<strong>Map:</strong>
</font>
</td>
<td width="320">
<font face="Arial" color="#999999" size="2">
<xsl:value-of select="qstat/server/map"/>
</font>
</td>
</tr>
<tr>
<td width="120">
<font face="Arial" color="#2f9ecb" size="2">
<strong>Server Name:</strong>
</font>
</td>
<td width="320">
<font face="Arial" color="#999999" size="2">
<xsl:value-of select="qstat/server/name"/>
</font>
</td>
</tr>
<tr>
<td width="120">
<font face="Arial" color="#2f9ecb" size="2">
<strong>Server Address:</strong>
</font>
</td>
<td width="320">
<font face="Arial" color="#999999" size="2">
<xsl:value-of select="qstat/server/hostname"/>
</font>
</td>
</tr>
<tr>
<td width="120">
<font face="Arial" color="#2f9ecb" size="2">
<strong>Ping:</strong>
</font>
</td>
<td width="320">
<font face="Arial" color="#999999" size="2">
<xsl:value-of select="qstat/server/ping"/>
</font>
</td>
</tr>
<tr>
<td width="120">
<font face="Arial" color="#2f9ecb" size="2">
<strong>Players:</strong>
</font>
</td>
<td width="320">
<font face="Arial">
<font size="2">
<font color="#999999">
<xsl:value-of select="qstat/server/numplayers"/> /
<xsl:value-of select="qstat/server/maxplayers"/>
</font>
</font>
</font>
</td>
</tr>
<tr>
<td width="120">
<font face="Arial" color="#2f9ecb" size="2">
<strong>Status:</strong>
</font>
</td>
<td width="320">
<font face="Arial">
<font color="#999999" size="2">
<xsl:value-of select="qstat/server/@status"/>
</font>
</font>
</td>
</tr>
</tbody>
</table>
<table width="440" border="0" style="; background-color: #444444">
<tbody>
<tr>
<td width="5%">
<img hspace="0" src="http://www.dirtyratsclan.com/images/blocks.gif" align="baseline" border="0"/>
</td>
<td width="55%">
<font face="Arial" color="#2f9ecb" size="2">
<strong>Player Details</strong>
</font>
</td>
</tr>
</tbody>
</table>
<table width="440">
<tbody>
<tr>
<td width="275">
<p align="center">
<font face="Arial" color="#2f9ecb" size="2">
<strong>Username</strong>
</font>
</p>
</td>
<td width="35">
<p align="center">
<font face="Arial" color="#999999" size="2">
<strong>
<font color="#2f9ecb">Team</font>
</strong><![CDATA[ ]]>
</font>
</p>
</td>
<td width="35">
<p align="center">
<img hspace="0" src="http://www.dirtyratsclan.com/images/score.jpg" align="baseline" border="0" style="width: 16px; height: 16px"/>
</p>
</td>
<td width="35">
<p align="center">
<img hspace="0" src="http://www.dirtyratsclan.com/images/deaths.jpg" align="baseline" border="0"/>
</p>
</td>
<td width="35">
<p align="center">
<img hspace="0" src="http://www.dirtyratsclan.com/images/ping.jpg" align="baseline" border="0"/>
</p>
</td>
</tr>
</tbody>
</table>
<table width="440" border="0">
<tbody>
<xsl:for-each select="qstat/server/players/player">
<xsl:sort select="team"/>
<tr>
<td width="300">
<p dir="ltr" align="left" style="margin-right: 0px">
<font face="Arial" color="#999999" size="2">
<xsl:value-of select="name"/>
</font>
</p>
</td>
<td width="35">
<p align="center">
<font face="Arial" color="#999999" size="2">
<xsl:value-of select="team"/>
</font>
</p>
</td>
<td width="35">
<p align="center">
<font face="Arial" color="#999999" size="2">
<xsl:value-of select="score"/>
</font>
</p>
</td>
<td width="35">
<p align="center">
<font face="Arial" color="#999999" size="2">
<xsl:value-of select="deaths"/>
</font>
</p>
</td>
<td width="35">
<p align="center">
<font face="Arial" color="#999999" size="2">
<xsl:value-of select="ping"/>
</font>
</p>
</td>
</tr>
</xsl:for-each>
</tbody>
</table>
<table width="440" style="; background-color: #444444">
<tbody>
<tr>
<td width="440"/>
</tr>
</tbody>
</table>
<br/>
</p>
</body>
</html>
</xsl:template>

<xsl:template name="NewTemplate0"/>
</xsl:stylesheet>

Thanks in advance,
Justin

Posttop
Minollo I.Subject: Newbie Help Needed (XSL Support Needed)
Author: Minollo I.
Date: 09 Apr 2006 10:07 PM
You need to run the XSLT writing code (C#) on your server side; an XSLT processor is part of the .NET framework.

Minollo

 
Topic Page 1 2 3 4 5 6 7 8 9 Go to previous topicPrev TopicGo to next topicNext Topic
Download A Free Trial of Stylus Studio 6 XML Professional Edition Today! Powered by Stylus Studio, the world's leading XML IDE for XML, XSLT, XQuery, XML Schema, DTD, XPath, WSDL, XHTML, SQL/XML, and XML Mapping!  
go

Log In Options

Site Map | Privacy Policy | Terms of Use | Trademarks
Stylus Scoop XML Newsletter:
W3C Member
Stylus Studio® and DataDirect XQuery ™are from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2011 All Rights Reserved.