title: dwr service class is not defined
body: <p>I am using dwr to send and get some information but i get  the following errore .</p>
  
  <pre><code>service(DwrSampleTest) is not defined
  </code></pre>
  
  <p>when i tried to use the following line to see the file : </p>
  
  <pre><code>http://localhost:8080/Servlets-DWR/dwr/index.html
  </code></pre>
  
  <p>i get the following exception : <code>Access to debug pages is denied.</code> </p>
  
  <p>here is my dwr.xml : </p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;!DOCTYPE dwr PUBLIC
  "-//GetAhead Limited//DTD Direct Web Remoting 2.0//EN"
  "http://getahead.org/dwr/dwr20.dtd"&gt;
  &lt;dwr&gt;
      &lt;allow&gt;
              &lt;create creator="new" javascript="Dwrsample"&gt;
              &lt;param name="class" value="com.dwrsample.servlet.DwrSampleTest"/&gt;
          &lt;/create&gt;
      &lt;/allow&gt;
  &lt;/dwr&gt;
  </code></pre>
  
  <p>web.xml : </p>
  
  <pre><code>&lt;servlet&gt;
          &lt;servlet-name&gt;dwr-invoker&lt;/servlet-name&gt;
          &lt;servlet-class&gt;org.directwebremoting.servlet.DwrServlet&lt;/servlet-class&gt;
          &lt;init-param&gt;
              &lt;param-name&gt;crossDomainSessionSecurity&lt;/param-name&gt;
              &lt;param-value&gt;false&lt;/param-value&gt;
          &lt;/init-param&gt;
          &lt;init-param&gt;
              &lt;param-name&gt;debug&lt;/param-name&gt;
              &lt;param-value&gt;false&lt;/param-value&gt;
          &lt;/init-param&gt;
      &lt;/servlet&gt;
      &lt;servlet&gt;
          &lt;servlet-name&gt;DwrsampleServlet&lt;/servlet-name&gt;
          &lt;servlet-class&gt;com.dwrsample.servlet.DwrsampleServlet&lt;/servlet-class&gt;
      &lt;/servlet&gt;
      &lt;servlet-mapping&gt;
          &lt;servlet-name&gt;dwr-invoker&lt;/servlet-name&gt;
          &lt;url-pattern&gt;/dwr/*&lt;/url-pattern&gt;
      &lt;/servlet-mapping&gt;
  </code></pre>
  
  <p>and the file where i call the method : </p>
  
  <pre><code>&lt;%@page contentType="text/html" pageEncoding="UTF-8"%&gt;
  &lt;!DOCTYPE html&gt;
  &lt;html&gt;
      &lt;head&gt;
          &lt;meta http-equiv="Content-Type" content="text/html; charset=UTF-8"&gt;
          &lt;title&gt;DWR Sample&lt;/title&gt;
          &lt;script src='dwr/dwr/engine.js'&gt;&lt;/script&gt;
          &lt;script src='dwr/dwr/util.js'&gt;&lt;/script&gt;
          &lt;script src='dwr/dwr/interface/DwrSampleTest.js'&gt;&lt;/script&gt;
  
          &lt;script&gt;
              function getName() {
                  DwrSampleTest.getName({callback:setName,async:false});
              }
              function setName(strName) {
                  document.getElementById("enterdwr").value = "";
                  document.getElementById("enterdwr").value = strName;
              }
          &lt;/script&gt;
      &lt;/head&gt;
      &lt;body&gt;
          &lt;h1&gt;DWR Sample Test!&lt;/h1&gt;
  
          &lt;form method="post" name="dwrsample" id="dwrsample"&gt;
              &lt;table&gt;
                  &lt;tr class="lightrow"&gt;
                      &lt;td width="1%"&gt;*&lt;/td&gt;
                      &lt;td width="39%"&gt;Eenter DWR&lt;/td&gt;
                      &lt;td width="60%"&gt;&lt;input name="enterdwr" id="password" type="text" onblur="getName()"/&gt;&lt;/td&gt;
                  &lt;/tr&gt;
                  &lt;tr class="lightrow"&gt;
                      &lt;td width="1%"&gt;*&lt;/td&gt;
                      &lt;td width="39%"&gt;DWR Result&lt;/td&gt;
                      &lt;td width="60%"&gt;&lt;input name="resultdwr" id="password" type="text" /&gt;&lt;/td&gt;
                  &lt;/tr&gt;
              &lt;/table&gt;
          &lt;/form&gt;
      &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>please help me to solve this.</p>