Sign Up! Login: Password: New User? Forgot? Support
Top Mods!
Wowhead Search
by sonofsamedi
Digital Clock
by Wolfar15
Admin Forums
Welcome to the GuildPortal Help Community! These forums are for admin-to-admin help.
Available Forums
Imperial-Fist (Guild Admin) 5/16/2004 7:49 AM EST : Relic XSL
Imperial-Fist
Posts: 361
Fingers of Fury!

Has anyone got an XSL for relic status they can post for me?


 No i am not going mad, it's just that people around me seem to be getting saner!


TopBottom

Cedricke (New Admin) 5/16/2004 2:15 PM EST : RE: Relic XSL
Cedricke
Posts: 745
Zomgawsh Poster

name="2579539">

You will want to replace 'Morgan' with the name of your appropriate server before using the following markup, but it reflects the Realm the relic belongs to as well as the current owner realm. If this isn't what you needed, just let me know and we'll see what else we can do.

You will want to use this, saved to an XSL file in conjunction with the http://www.camelotherald.com/xml/servers.xml file

-------------------Snip---------------------------------------

<?xml version="1.0"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
   <xsl:template match="server_status">
      <html>
         <body vlink="#FFFFE0" link="#FFFFE0">
            <table border="0" bgcolor="black" align="center" cellpadding="0" cellspacing="0" width="400px">
               <tr>
                  <td valign="top">
                     <xsl:apply-templates select="server[@name = 'Pendragon']"/>
                  </td>
                  <td valign="top">
                     <table width="100%" border="0" cellpadding="1" cellspacing="2">
                        <tr>
                           <td align="center"><font face="verdana" size="1" color="white">Type</font></td>
                        </tr>
                        <tr>
                           <td align="center" bgcolor="#8D0012"><font face="verdana" size="1" color="white">Strength</font></td>
                        </tr>
                        <tr>
                           <td align="center" bgcolor="#8D0012"><font face="verdana" size="1" color="white">Power</font></td>
                        </tr>
                        <tr>
                           <td align="center" bgcolor="#095091"><font face="verdana" size="1" color="white">Strength</font></td>
                        </tr>
                        <tr>
                           <td align="center" bgcolor="#095091"><font face="verdana" size="1" color="white">Power</font></td>
                        </tr>
                        <tr>
                           <td align="center" bgcolor="#476600"><font face="verdana" size="1" color="white">Strength</font></td>
                        </tr>
                        <tr>
                           <td align="center" bgcolor="#476600"><font face="verdana" size="1" color="white">Power</font></td>
                        </tr>
                     </table>
                  </td>
                  <td valign="top">
                     <xsl:apply-templates select="server[@name = 'Morgan']"/>
                  </td>
               </tr>
            </table>
            <table border="0" bgcolor="black" align="center" cellpadding="0" cellspacing="0" width="400px">
               <tr>
                  <td colspan="5" align="center" bgcolor="black">
                     <font face="verdana" size="1" color="white">
                     <b>COLOR KEY</b>
                     </font>
                  </td>
               </tr>
               <tr>
                  <td bgcolor="#8D0012" align="center" width="30%">
                     <font face="verdana" size="1" color="white">
                     <b>Albion</b>
                     </font>
                  </td>
                  <td bgcolor="#095091" align="center" width="30%">
                     <font face="verdana" size="1" color="white">
                     <b>Midgard</b>
                     </font>
                  </td>
                  <td bgcolor="#476600" align="center" width="30%">
                     <font face="verdana" size="1" color="white">
                        <b>Hibernia</b>
                     </font>
                  </td>
               </tr>
            </table>
         </body>
   </html>
</xsl:template>
 
<xsl:template match="server">
   <xsl:if test="@name = 'Pendragon'">
      <table width="100%" border="0" cellpadding="1" cellspacing="2">
         <tr>
            <td align="center"><font face="verdana" size="1" color="white">Relic Name</font></td>
         </tr>
         <xsl:for-each select="relic">
            <xsl:variable name="color_realm">
               <xsl:choose>
                  <xsl:when test="@realm='Albion'">#8D0012</xsl:when>
                  <xsl:when test="@realm='Midgard'">#095091</xsl:when>
                  <xsl:when test="@realm='Hibernia'">#476600</xsl:when>
               </xsl:choose>
            </xsl:variable>
            <tr>
               <td bgcolor="{$color_realm}" align="center"><font face="verdana" size="1" color="white"><xsl:value-of select="@name"/></font></td>
            </tr>
         </xsl:for-each>
      </table>
   </xsl:if>
   <xsl:if test="@name = 'Morgan'">
      <table width="100%" border="0" cellpadding="1" cellspacing="2">
         <tr>
            <td align="center"><font face="verdana" size="1" color="white"><xsl:value-of select="@name"/></font></td>
         </tr>
         <xsl:for-each select="relic">
            <xsl:variable name="bgcolor_owner">
               <xsl:choose>
                  <xsl:when test="owner='Albion'">#8D0012</xsl:when>
                  <xsl:when test="owner='Midgard'">#095091</xsl:when>
                  <xsl:when test="owner='Hibernia'">#476600</xsl:when>
               </xsl:choose>
            </xsl:variable>
            <tr>
               <td bgcolor="{$bgcolor_owner}" align="center"><font face="verdana" size="1" color="white"><xsl:value-of select="owner"/></font></td>
            </tr>
         </xsl:for-each>
      </table>
   </xsl:if>
</xsl:template>
</xsl:stylesheet>
-------------------End Snip-----------------------------------

TopBottom

Imperial-Fist (Guild Admin) 5/18/2004 11:30 AM EST : RE: Relic XSL
Imperial-Fist
Posts: 361
Fingers of Fury!

Thankyou very much, that was perfect


 No i am not going mad, it's just that people around me seem to be getting saner!


TopBottom

Cedricke (New Admin) 5/18/2004 2:48 PM EST : RE: Relic XSL
Cedricke
Posts: 745
Zomgawsh Poster

Glad to help Imp. Enjoy.
TopBottom

Admins Online
There are   members online.
So-and-so has logged on!
%title%
%message%