<%@ taglib uri="/tld/jx.tld" prefix="jx" %>
<%@ taglib uri="/tld/im.tld" prefix="im" %>
<%@ taglib uri="/tld/desktop.tld" prefix="dt" %>
<%@ taglib uri="/tld/desktopProviderContext.tld" prefix="dtpc" %>
<dt:obtainChannel channel="$JSPProvider">

<?xml version="1.0" encoding="utf-8"?>
<!-- JNLP File for IM Application -->
<jnlp
  spec="1.0+"
  codebase="<im:getCodebase/>">
  <information>
    <title>IM</title>
    <vendor>Sun Microsystems, Inc.</vendor>
    <homepage href="help/getstart.htm"/>
    <description>Sun Java System Instant Messenger</description>
    <description kind="short">Instant Messenger</description>
    <icon href="IM_JLF32x.gif"/>
    <offline-allowed/>
  </information>
  <security>
    <all-permissions/>
  </security>
  <resources>
    <j2se version="1.3+">
      <resources>
        <jar href="<dtpc:getLocaleString/>/imres.jar"/>
        <jar href="<dtpc:getLocaleString/>/imbrand.jar"/>
      </resources>
    </j2se>
    <jar href="messenger.jar"/>
    <jar href="imdesktop.jar"/>
    <jar href="imnet.jar"/>
    <jar href="icalendar.jar"/>
    <nativelib href="imjni.jar"/>
  </resources>
  <application-desc main-class="com.iplanet.im.client.iIM">
    <argument>server=<im:getIMServer/></argument>
    <argument>uid=<im:getUsername/></argument>
    <argument>token=<im:getToken/></argument>
<% String src =	request.getParameter("src_url");
   if (src != null) {
     String myURL = HttpUtils.getRequestURL(request).toString().toLowerCase();
     if (!myURL.startsWith(src.toLowerCase())) { %>
       <argument>gateway_url=<%= src %></argument>
<%   } 
   }
%>
<% if (request.getParameter("username") != null) { %>
    <argument>autoinvite=<%= request.getParameter("username") %></argument>
<% } %>
  </application-desc>
</jnlp>
</dt:obtainChannel>

