Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. Placing/Integrating a Web Service With A Web Site

Placing/Integrating a Web Service With A Web Site

Scheduled Pinned Locked Moved ASP.NET
htmldatabasesysadminhostingxml
3 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • G Offline
    G Offline
    Gaul
    wrote on last edited by
    #1

    We have a publicly hosted website (hosted by a hosting company) that is used for capturing data that is stored in a database, and need to be able to download that data at periodic intervals to a server on company intranet. One solution we have considered is to place a Web Service on the Web Site, or in a subdirectory of the website. That does not seem to be working as the Web Service is returning an error of content-type of text/html when text/xml is being expected. "Client found response content type of 'text/html; charset=utf-8', but expected 'text/xml'...". The website has a global.aspx handler that is processed for each request, and one of the things that does is to read a configuration file that is used to populate the pages to be displayed. The webservice does not require the global.aspx, but even when we place the webservice in a subdirectory of the website, it looks like the global.aspx is still being processed, and this may be responsible for the text/html being returned. Are we doing it right? Will appreciate any suggestions or alternatives on how to go about this. We want to place the web service so that it can be called from applications on the intranet to read the data from the same database as the web application. Gaulles

    G 1 Reply Last reply
    0
    • G Gaul

      We have a publicly hosted website (hosted by a hosting company) that is used for capturing data that is stored in a database, and need to be able to download that data at periodic intervals to a server on company intranet. One solution we have considered is to place a Web Service on the Web Site, or in a subdirectory of the website. That does not seem to be working as the Web Service is returning an error of content-type of text/html when text/xml is being expected. "Client found response content type of 'text/html; charset=utf-8', but expected 'text/xml'...". The website has a global.aspx handler that is processed for each request, and one of the things that does is to read a configuration file that is used to populate the pages to be displayed. The webservice does not require the global.aspx, but even when we place the webservice in a subdirectory of the website, it looks like the global.aspx is still being processed, and this may be responsible for the text/html being returned. Are we doing it right? Will appreciate any suggestions or alternatives on how to go about this. We want to place the web service so that it can be called from applications on the intranet to read the data from the same database as the web application. Gaulles

      G Offline
      G Offline
      Guffa
      wrote on last edited by
      #2

      Open the properties for the subdirectory in the IIS manager, and create an application for it (there is a button for that). It's now a separate application, and does not use anything from the application in the root folder.

      --- b { font-weight: normal; }

      G 1 Reply Last reply
      0
      • G Guffa

        Open the properties for the subdirectory in the IIS manager, and create an application for it (there is a button for that). It's now a separate application, and does not use anything from the application in the root folder.

        --- b { font-weight: normal; }

        G Offline
        G Offline
        Gaul
        wrote on last edited by
        #3

        Thanks for your suggestion. We tried it on the intranet, and it worked. We are yet to try it on the publicly hosted website. We have no access to IIS on the hosting company's machine, but would request that they create the applicaton for us. I believe it should work also. Gaulles

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups