Setting the ContentType for content published using a VirtualPathProvider

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Jan

    Setting the ContentType for content published using a VirtualPathProvider

    Is it possible to set the ContentType for the VirtualFile-descendant that a
    custom virtual path provider returns in response to a call to its GetFile
    method? Right now, web browsers tend to misinterpret the XML-data I return,
    because I cannot specify that the content type is text/xml.

  • =?Utf-8?B?YnJ1Y2UgYmFya2Vy?=

    #2
    RE: Setting the ContentType for content published using a VirtualPathP

    see iis mime mapping in the vdir

    -- bruce (sqlwork.com)


    "Jan" wrote:
    Is it possible to set the ContentType for the VirtualFile-descendant that a
    custom virtual path provider returns in response to a call to its GetFile
    method? Right now, web browsers tend to misinterpret the XML-data I return,
    because I cannot specify that the content type is text/xml.
    >
    >

    Comment

    • Jan

      #3
      Re: Setting the ContentType for content published using a VirtualPathP

      Thanks, Bruce!

      Perhaps I misunderstood your reply - if I'm running my code directly from
      Visual Studio 2005, using the built-in development web server, where can I
      set MIME mappings?

      "bruce barker" <brucebarker@di scussions.micro soft.comwrote in message
      news:3E263BE1-1762-41AD-A66A-C2D9CB74571C@mi crosoft.com...
      see iis mime mapping in the vdir
      >
      -- bruce (sqlwork.com)
      >
      >
      "Jan" wrote:
      >
      >Is it possible to set the ContentType for the VirtualFile-descendant that
      >a
      >custom virtual path provider returns in response to a call to its GetFile
      >method? Right now, web browsers tend to misinterpret the XML-data I
      >return,
      >because I cannot specify that the content type is text/xml.
      >>
      >>

      Comment

      Working...