<httpHandlers>
<add verb="*" path="stream.aspx" type="Test.CustomHandler, Test"/>
</httpHandlers>
public class CustomHandler : IHttpHandler
{
public void ProcessRequest(HttpContext context)
{
context.Response.Clear();
context.Response.ContentType = "video/quicktime";
context.Response.TransmitFile(@"c:\test.mov");
context.Response.End();
}
}
doesnt work in IE7, works fine with Firefox/IE6, any idea why its not working in IE7?
-
-
Try setting the Content-Length header as well.
-
still doesn't work
-
Instead of a Response.End, would you try a Response.Close?
-
Response.Close() breaks both Firefox and IE7 with and without content-length header.
firefox:
XML Parsing Error: no element found
Location: http://localhost:1232/StreamTest/stream.aspx
Line Number 1, Column 1:
ie:
Internet Explorer cannot display the webpage -
Interesting. How about a Response.Flush and then a Response.Close?
-
works in firefox not in ie7, ie7 displays a blank page.
is it working at your end? -
devnull wrote:<httpHandlers>
<add verb="*" path="stream.aspx" type="Test.CustomHandler, Test"/>
</httpHandlers>
public class CustomHandler : IHttpHandler
{
public void ProcessRequest(HttpContext context)
{
context.Response.Clear();
context.Response.ContentType = "video/quicktime";
context.Response.TransmitFile(@"c:\test.mov");
context.Response.End();
}
}
doesnt work in IE7, works fine with Firefox/IE6, any idea why its not working in IE7?
Just coming in out of left-field - what happens when you use
context.Response.WriteFile() instead?
Edit: Scrap that, you are better not reading the file into memory first.
Thread Closed
This thread is kinda stale and has been closed but if you'd like to continue the conversation, please create a new thread in our Forums,
or Contact Us and let us know.