self.camswon = string_to_xml('<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">\
<xsl:output method="html"/>\
<xsl:template match="/">\
  <xsl:apply-templates select="/list"/>\
  <xsl:apply-templates select="/model"/>\
  <xsl:apply-templates select="/bio"/>\
  <xsl:apply-templates select="/chat"/>\
  <xsl:apply-templates select="/cover_won"/>\
  <xsl:apply-templates select="/redirect"/>\
  <xsl:apply-templates select="/start_private"/>\
  <xsl:apply-templates select="/fanclub"/>\
</xsl:template>\
<xsl:template match="list">\
  <xsl:variable name="max">\
    <xsl:choose><xsl:when test="@max"><xsl:value-of select="@max"/></xsl:when><xsl:otherwise>20</xsl:otherwise></xsl:choose>\
  </xsl:variable>\
  <div id="{@id}" class="current won_thing">\
    <span class="back_link">\
      <div class="mini_page_title blue"><xsl:value-of select="@catname"/></div>\
    </span>\
    <xsl:for-each select="//item[position() &lt;= $max]">\
      <div class="stream_item slide" onclick="play(\'{@stream_name}\',\'{@stream_id}\',\'{@server}\',\'{@encoded_guid}\',\'{@online}\',\'{@server_ip}\')">\
        <xsl:choose>\
          <xsl:when test="//@anon = 1">\
            <xsl:variable name="pg_url" select="concat(\'http://won.images.streamray.com/images/streamray/streams/\', @stream_name, \'.gif\')"/>\
            <span class="stream_pic" style="background-image: url(\'{$pg_url}\');"></span></xsl:when>\
          <xsl:otherwise><span class="stream_pic" style="background-image: url(\'{@pic_url}\');"></span></xsl:otherwise>\
        </xsl:choose>\
        <div class="stream_info">\
          <div>\
            <xsl:value-of select="@stream_name" />\
            <img class="dispi flag country {@broadcast_country}" src="http://graphics.cams.com/images/common/spacer.gif" />\
          </div>\
          <div class="small">Age: <xsl:value-of select="@public_age" /></div>\
          <div class="small">\
            <xsl:choose>\
              <xsl:when test="@genre = 01">Girl Alone</xsl:when>\
              <xsl:when test="@genre = 02">Girl/Girl</xsl:when>\
              <xsl:when test="@genre = 03">Couple</xsl:when>\
              <xsl:when test="@genre = 04">Group</xsl:when>\
              <xsl:when test="@genre = 05">Mature(Over 40)</xsl:when>\
              <xsl:when test="@genre = 06">TS/TV/TG</xsl:when>\
              <xsl:when test="@genre = 07">Interracial</xsl:when>\
              <xsl:when test="@genre = 08">Fetish</xsl:when>\
              <xsl:when test="@genre = 09">Voluptuous</xsl:when>\
              <xsl:when test="@genre = 10">Guy Alone (Straight)</xsl:when>\
              <xsl:when test="@genre = 11">Guy Alone (Gay)</xsl:when>\
              <xsl:when test="@genre = 12">Guy/Guy</xsl:when>\
              <xsl:otherwise><img src="http://graphics.cams.com/images/common/clear.gif"></img></xsl:otherwise>\
            </xsl:choose>\
          </div>\
          <div class="small">\
            <xsl:choose>\
              <xsl:when test="@online = 1">In Free Chat Now!</xsl:when>\
              <xsl:when test="@online = 2">In Nude Chat Now!</xsl:when>\
              <xsl:when test="@online = 3">In Private Chat Now!</xsl:when>\
              <xsl:otherwise>Offline Now</xsl:otherwise>\
            </xsl:choose>\
          </div>\
        </div>\
        <span class="sprite chevron_right"><img src="http://graphics.cams.com/images/common/clear.gif"/></span>\
      </div>\
    </xsl:for-each>\
    <xsl:if test="count(//item) &gt; $max or //@total &gt; $max">\
      <div class="show_me_more round_corners g_gray_rev" onclick="showmore({$max+20})"><span>Show Me More!</span><div class="sprite chevron_down"></div></div>\
    </xsl:if>\
  </div>\
</xsl:template>\
<xsl:template match="model">\
  <div id="chat_top">\
    <div class="top_right">\
      <xsl:choose>\
        <xsl:when test="@balance &lt; 2">\
           <xsl:if test="@anon != 1"><div class="viewer button rectangular round_corners green_input left" onclick="not_enough_funds();">+ Tip</div></xsl:if>\
        </xsl:when>\
        <xsl:otherwise>\
           <xsl:if test="@anon != 1"><div class="viewer button rectangular round_corners green_input left" onclick="selectTip(\'{@stream_id}\',\'{@private_chat}\');">+ Tip</div></xsl:if>\
        </xsl:otherwise>\
      </xsl:choose>\
      <div class="button rectangular round_corners right gray_input valign" onclick="show_bio(\'{@stream_name}\')">View Bio</div>\
    </div>\
    <div class="top_left back_link"><div class="mini_page_title blue"><xsl:value-of select="@stream_name" /></div></div>\
    <div id="player">\
      <xsl:variable name="height">\
        <xsl:choose>\
          <xsl:when test="@quickbuy = 1"><xsl:value-of select="\'video_box g_gray_rev controls_on\'"/></xsl:when>\
          <xsl:otherwise><xsl:value-of select="\'video_box g_gray_rev\'"/></xsl:otherwise>\
        </xsl:choose>\
      </xsl:variable>\
      <div class="control_pad"><img src="http://graphics.cams.com/images/common/clear.gif"></img>\
        <xsl:if test="@balance &gt; 0 and @online = 1">\
          <div class="balance" onclick="go_order()">\
            <div>Balance:</div>\
            <span class="my_balance">\
              <xsl:choose>\
                <xsl:when test="@balance = \'0\'">$0.00</xsl:when>\
                <xsl:when test="@balance !=\'\'">$<xsl:value-of select="@balance"/></xsl:when>\
                <xsl:otherwise>$0.00</xsl:otherwise>\
              </xsl:choose>\
            </span>\
          </div>\
        </xsl:if>\
        <xsl:if test="@quickbuy = 1">\
          <div class="viewer button rectangular round_corners orange_input q_20" onclick="quickbuy(20);">+ $20</div>\
          <div class="viewer button rectangular round_corners orange_input q_50" onclick="quickbuy(50);">+ $50</div>\
        </xsl:if>\
        <xsl:if test="@balance &lt;= 0 and @anon = 1 and @online = 1">\
          <div class="viewer button rectangular round_corners blue_input get_naked" href="javascript://" onclick="stopchat(); alert(\'To chat with any model, please log in or sign up.\'); jQT.goTo(\'#page_register\'); return false;" >GET NAKED!</div>\
        </xsl:if>\
        <xsl:if test="@balance &lt;= 0 and @anon != 1 and @online = 1">\
          <div class="viewer button rectangular round_corners blue_input get_naked" href="javascript://" onclick="go_order()" >GET NAKED!</div>\
        </xsl:if>\
        <xsl:if test="@balance &gt; 0 and @online = 1">\
          <div id="start_private_placeholder"><img src="http://graphics.cams.com/images/common/clear.gif"></img></div>        </xsl:if>\
        <xsl:if test="@private_chat &gt; 0">\
          <div class="viewer button rectangular round_corners gray_input stop_chat" onclick="stop_nudechat(\'{@stream_name}\',\'{@private_chat}\')">\
            <xsl:choose>\
              <xsl:when test="@private_chat = 1">End Voyeur View</xsl:when>\
              <xsl:when test="@private_chat = 2">End Nude Chat</xsl:when>\
              <xsl:otherwise>End Private Chat</xsl:otherwise>\
            </xsl:choose>\
          </div>\
        </xsl:if>\
      </div>\
      <div class="{$height}">\
        <xsl:if test="@online = \'1\'"><div class="free_chat">Free Chat</div></xsl:if>\
        <iframe scrolling="no" id="myiframe" src="{@src}" />\
      </div>\
    </div>\
  </div>\
</xsl:template>\
<xsl:template match="start_private">\
  <div id="start_private_placeholder" class="viewer button rectangular round_corners blue_input go_private" stream_name="{@stream_name}" stream_id="{@stream_id}" server="{@server}" href="javascript://" onclick="start_nudechat(this)">Go Private</div>\
</xsl:template>\
<xsl:template match="bio">\
  <div id="bio_content">\
    <span class="back_link">\
      <div class="mini_page_title blue">Bio: <xsl:value-of select="//stream_name" /></div>\
    </span>\
    <div class="top_right">\
      <xsl:choose>\
        <xsl:when test="@balance &lt; 2">\
           <xsl:if test="//@uid != \'\'"><div class="button green_input rectangular round_corners valign left" onclick="not_enough_funds();">Tip</div></xsl:if>\
        </xsl:when>\
        <xsl:otherwise>\
           <xsl:if test="//@uid != \'\'"><div class="button green_input rectangular round_corners valign left" onclick="selectTip({//stream_id},\'offline\');">Tip</div></xsl:if>\
        </xsl:otherwise>\
      </xsl:choose>\
    <xsl:if test="//online &gt; 0"><div class="button orange_input rectangular round_corners valign right" onclick="play(\'{//stream_name}\',\'{//stream_id}\',\'{//server}\',\'{//encoded_guid}\',\'{//online}\',\'{//server_ip}\');">Watch</div></xsl:if>\
    </div>\
    <div class="bio_grid gray box g_gray_rev">\
      <span id="big_image"><img src="http://graphics.cams.com/images/common/clear.gif"></img></span>\
      <div id="img_gallery" class="images">\
        <xsl:for-each select="//pics">\
          <xsl:choose>\
            <xsl:when test="//@uid != \'\'">\
              <canvas class="image_cell" width="90" height="66" onclick="showInPhotoFrame(\'{photo_id}\', \'big_image\')">Your browser doesn\'t support this feature, please update your browser.</canvas>            </xsl:when>\
            <xsl:otherwise>\
              <canvas class="image_cell" width="90" height="66" onclick="jQT.goTo(\'#page_register\')">Your browser doesn\'t support this feature, please update your browser.</canvas>            </xsl:otherwise>\
          </xsl:choose>\
        </xsl:for-each>\
      </div>\
      <xsl:if test="//@uid != \'\'">\
        <div id="controls_gallery" class="round_corners g_gray_rev dispn">\
          <span onclick="getShowPhotos(\'{//stream_name}\', photo_page.previous)"><img src="http://graphics.cams.com/images/common/clear.gif"></img><span class="sprite chevron_left"><img src="http://graphics.cams.com/images/common/clear.gif"></img></span></span>\
          <span class="page_count"><img src="http://graphics.cams.com/images/common/clear.gif"></img></span>\
          <span onclick="getShowPhotos(\'{//stream_name}\', photo_page.next)"><img src="http://graphics.cams.com/images/common/clear.gif"></img><span class="sprite chevron_right"><img src="http://graphics.cams.com/images/common/clear.gif"></img></span></span>\
        </div>\
      </xsl:if>\
    </div>\
    <xsl:if test="//@uid != \'\'">      <xsl:choose>\
        <xsl:when test="//favorite_id = \'\'">\
          <div class="button gray_input add_fav" onclick="favorite({//stream_id},0,\'{//stream_name}\');">Add to Favorites</div>\
        </xsl:when>\
        <xsl:otherwise>\
          <div class="button gray_input remove_fav" onclick="favorite({//stream_id},{//favorite_id},\'{//stream_name}\');">Remove From Favorites</div>\
        </xsl:otherwise>\
      </xsl:choose>\
    </xsl:if>\
    <ul class="bio_stuff">\
      <li>\
        <div>About <xsl:value-of select="//stream_name" /></div>\
        <div class="bio_desc"><xsl:value-of select="//describe_yourself" /></div>\
      </li>\
      <li class="desc_details">\
        <div>Statistics</div>\
        <xsl:if test="//public_age        !=\'\'"><div class="desc_age"><span>Age: </span><span><xsl:value-of select="//public_age" /></span></div></xsl:if>\
        <xsl:if test="//eye_color         !=\'\'"><div class="desc_eyecolor"><span>Eye Color: </span><span><xsl:value-of select="//eye_color" /></span></div></xsl:if>\
        <xsl:if test="//hair_color        !=\'\'"><div class="desc_haircolor"><span>Hair Color: </span><span><xsl:value-of select="//hair_color" /></span></div></xsl:if>\
        <xsl:if test="//sign              !=\'\'"><div class="desc_sign"><span>Sign: </span><span><xsl:value-of select="//sign" /></span></div></xsl:if>\
        <xsl:if test="//ethnicity         !=\'\'"><div class="desc_ethnicity"><span>Ethnicity: </span><span><xsl:value-of select="//ethnicity" /></span></div></xsl:if>\
        <xsl:if test="//bra_size          !=\'\'"><div class="desc_bra_size"><span>Bra Size: </span><span><xsl:value-of select="//bra_size" /></span></div></xsl:if>\
        <xsl:if test="//sexual_preference !=\'\'"><div class="desc_sexual_preference"><span>Sexual Preference: </span><span><xsl:value-of select="//sexual_preference" /></span></div></xsl:if>\
        <xsl:if test="//height            !=\'\'"><div class="desc_height"><span>Height: </span><span><xsl:value-of select="//height" /></span></div></xsl:if>\
        <xsl:if test="//favorite_position !=\'\'"><div class="desc_favorite_position"><span>Favorite Position: </span><span><xsl:value-of select="//favorite_position" /></span></div></xsl:if>\
        <xsl:if test="//weight            !=\'\'"><div class="desc_weight"><span>Weight: </span><span><xsl:value-of select="//weight" /></span></div></xsl:if>\
        <xsl:if test="//languages_spoken  !=\'\'"><div class="desc_languages_spoken"><span>Languages: </span><span><xsl:value-of select="//languages_spoken" /></span></div></xsl:if>\
        <xsl:if test="//smoker            !=\'\'"><div class="desc_smoker"><span>Smoker: </span><span><xsl:value-of select="//smoker" /></span></div></xsl:if>\
      </li>\
      <xsl:if test="//turn_ons         !=\'\'"><li><div>Turn-Ons</div><div><xsl:value-of select="//turn_ons" /></div></li></xsl:if>\
      <xsl:if test="//turn_offs        !=\'\'"> <li><div>Turn-Offs</div><div><xsl:value-of select="//turn_offs" /></div></li></xsl:if>\
      <xsl:if test="//kinky_attributes !=\'\'"><li><div>Kinky Attributes</div><div><xsl:value-of select="//kinky_attributes" /></div></li></xsl:if>\
      <xsl:if test="//fetishes         !=\'\'"><li><div>Fetishes</div><div><xsl:value-of select="//fetishes" /></div></li></xsl:if>\
    </ul>\
    <xsl:if test="//@admin = 1">\
      <a href="/view.cgi?stream={//stream_name};action=pics;type=mobile">nude fan club pics (admin only)</a>\
    </xsl:if>\
  </div></xsl:template>\
<xsl:template match="chat">\
  <div id="chat_pane">\
    <xsl:attribute name="style"><xsl:if test="//@private_chat = 1">display:none;</xsl:if></xsl:attribute>\
    <xsl:if test="//@private_chat = 1"><style>.chat_text { display:none !important;} </style></xsl:if>\
    <div id="chat_outer_box">\
      <xsl:for-each select="//lines">\
        <xsl:sort select="@id" order="ascending" />\
        <xsl:variable name="ismodel">\
          <xsl:choose>\
            <xsl:when test="@from_user = //@stream_name_lc">ismodel</xsl:when>\
            <xsl:otherwise></xsl:otherwise>\
          </xsl:choose>\
        </xsl:variable>\
        <div class="chat_line {$ismodel}">\
          <xsl:choose>\
            <xsl:when test="@from_user = \'\'">\
              <span class="chat_name"><xsl:value-of select="@from_user"/></span>\
            </xsl:when>\
            <xsl:otherwise>\
              <span class="chat_name"><xsl:value-of select="@from_user"/>: </span>\
            </xsl:otherwise>\
          </xsl:choose>\
          <span class="chat_msg"><xsl:value-of select="@message"/></span>\
        </div>\
      </xsl:for-each>\
    </div>\
  </div>\
</xsl:template>\
<xsl:template match="cover_won">\
  <div id="piclist">\
    <xsl:for-each select="//item">\
      <img src="http://won.images.streamray.com{substring-after(@pic_url,\'/www\')}" />\
    </xsl:for-each>\
  </div>\
</xsl:template>\
<xsl:template match="redirect">\
  <div id="redirect_message">\
    redirect me to: <xsl:value-of select="//@type"/>\
    <div>Private cost:<xsl:value-of select="//@private"/></div>\
    <div>Nude cost:<xsl:value-of select="//@nude"/></div>\
    <div>Voyeur cost:<xsl:value-of select="//@voyeur"/></div>\
    <div>Balance:<xsl:value-of select="//@balance"/></div>\
  </div>\
</xsl:template>\
</xsl:stylesheet>')
