[CLOSED] Webservice treeloader in the IIS server not working

  1. #1

    [CLOSED] Webservice treeloader in the IIS server not working

    Hello

    I am using a webservice to load a treepanel. This works fine locally, as soon as I deploy it to a staging server in IIS it does not work:
    • localhost/treepanel.aspx works
    • myserver/treepanel.aspx has a js error (Line 11):
      Uncaught TypeError: Cannot read property 'documentElement' of null
      Ext.NetServiceTreeLoader.Ext.extend.processResponseWebResource.axd:832
      Ext.extend.handleResponseWebResource.axd:7
      Ext.extend.handleResponse
      
      js:
      Ext.NetServiceTreeLoader=Ext.extend(Ext.tree.TreeLoader,
      {processResponse:function(response,node,callback)
      {var json,root;
      if(this.json){root=Ext.decode(response.responseText);json=root.d||root;}
      else{var xmlData=response.responseXML;root=xmlData.documentElement||xmlData;json=Ext.DomQuery.selectValue("json",root,"");}
    • myserver/WebService/TreeLoader.asmx is ok, can be openend.


    It can be related to this post: http://forums.ext.net/showthread.php...duction-server
    but I don't see any suggested solution there.

    Is this problem known to anyone? is it a iis configuration thing? any idea?

    thanks.
    Last edited by Daniil; Feb 20, 2012 at 1:02 PM. Reason: [CLOSED]
  2. #2
    Please post response for webservice request (request is initiated from your treepanel.aspx to server with IIS)
    You can get that response from Fiddler
  3. #3
    hi Danill

    I have the response (status 302) now:
    <html><head><title>Object moved</title></head><body>
    <h2>Object moved to <a href="/myapp/ErrorPage.aspx?aspxerrorpath=/myapp/WebService/TreeLoaders/LocTreeLoader.asmx/GetNodes">here</a>.</h2>
    </body></html>
    Last edited by Daniil; Feb 20, 2012 at 1:01 PM. Reason: Please use [CODE] tags
  4. #4
    So, IIS makes redirect to "/myapp/ErrorPage.aspx" because requested url "/myapp/WebService/TreeLoaders/LocTreeLoader.asmx/GetNodes" is not valid or server side exception is occured during GetNodes method execution

    Check you error log (possible server side exceptions), ensure that url is valid
  5. #5

    [CLOSED]

    Thank you for the help, Valdimir
    (ps. sorry my last post was adressed to Danill due to his ubiquitous responses to my posts;))

    It was a configuration stuff finally (see KB): by default http GET and http Post are disabled in .net, when the applcation is not in localhost. Following should be added in web.config

    <configuration>
        <system.web>
        <webServices>
            <protocols>
                <add name="HttpGet"/>
                <add name="HttpPost"/>
            </protocols>
        </webServices>
        </system.web>
    </configuration>

Similar Threads

  1. Replies: 0
    Last Post: Sep 05, 2011, 2:59 PM
  2. Replies: 2
    Last Post: Apr 04, 2011, 12:32 PM
  3. [CLOSED] [1.0]TreeLoader.ClearOnLoad not always working
    By tdracz in forum 1.x Legacy Premium Help
    Replies: 8
    Last Post: Apr 23, 2010, 9:57 AM
  4. Replies: 5
    Last Post: May 13, 2009, 12:10 PM
  5. store databind from server not working
    By Devworks in forum 1.x Help
    Replies: 11
    Last Post: Feb 06, 2009, 11:14 AM

Tags for this Thread

Posting Permissions