http

Can I send a HTTP redirect to a url with an anchor?

Is it possible to send a response with 302 status code to a url like this: http://mysite.com/something/#somethingelse ...

How to force a web browser to cache Images

I am writing a small application which serves images from the local computer, so they can be accessed as http://localhost:12345/something/something (which returns a jpeg). How can I force the browser to cache this, so only a single request would be sent to the server. Would this header be sufficient HTTP/1.1 200 OK Cache-Control: publ...

How to obtain the FINAL redirected URL using Coldfusion

Given a URL like: before: http://feeds.wsjonline.com/~r/wsj/health/feed/~3/felKuQPa41U/ which redirects eventually to: after: http://blogs.wsj.com/health/2009/08/14/insurance-salesman-to-obama-why-are-you-vilifying-insurers/ Using Coldfusion, how can I obtain that final (after) URL? I believe CFHTTP will redirect automatically up t...

Detect/estimate country of a http-request in ASP.NET

Hello, I'm looking for ways to detect/estimate the country from which a http-request is coming in ASP.NET. I know there are some solutions with services/country lookups but I never used one. I'm looking for small/clean solutions. It's for helping someone filling out a form so it does not have to be 100% accurate. Thanks in advance.. ...

Access Request Body in a WCF RESTful Service

Hi, How do I access the HTTP POST request body in a WCF REST service? Here is the service definition: [ServiceContract] public interface ITestService { [OperationContract] [WebInvoke(Method = "POST", UriTemplate = "EntryPoint")] MyData GetData(); } Here is the implementation: public MyData GetData() { return new MyD...

What is apache's maximum url length?

What is the maximum length of a URL in apache? Where is it documented, and is it configurable? I'm implementing an openid identity provider, and would like to know the limitations I'm up against. I know about the 2048 byte path limit on Internet Explorer. That can be handled specially using user agent detection. Other browsers have much...

HTTP connection with NSURLConnection in iphone

Hi, Thanks a lot for reply. I am stuck here. Can you please help with this situation? Can CFHTTPStream will resolve this problem? Is there any other way to work with this problem ? Thanks. Hi, I am connecting to an HTTP url using NSURLConnection. I am supposed to get response after some time intervals (The response is not getting close...

Is there any concurrent HTTP requests limitation for Silverlight?

I know that RFC requires UserAgent to have a limit of max 2 http connection to single server. In fact, most browsers have the limit larger than 2. The question is whether Silverlight have such limitation. Does it follow limit of hosting web browser? or does it has its own max connection limit? ...

Download when idle/low network utilization

I have an update service that needs to pull data down from remote, however like Microsoft's BITS I'd like to do this when the user is idle and/or when their network utilisation is low so as to not impact on their experience. What do I need to do or look at? Can anyone point me in the right direction on where to start with this and get t...

How can I use VB.Net to read the content returned from a URL?

Below is the example code I'm using to get this to work and it does work if I try to read yahoo.com. Here is the problem. The address I need to read is a java servlet that processes parameters passed in, generates a text document on the server, and then redirects to another URL and returns the address of the text file on the server. I...

SSL Certificate only works within Local Network

I am running windows server 2003 standard and have installed the ssl cert as per Godaddy's instructions. Let me know what information you need from me. Attempting to access the website securely outside of our network the page does not load. Thanks in advance! ...

ReturnUrl and preserve scroll position?

How do I indicate position on page in returnUrl? returnUrl= HttpContext.Current.Request.RawUrl ...

Reasons why gzipped content might not be grokked by the browser

I'm attempting to serve static resources (css and javascript) as cached gzipped files for performance reasons. The pages look gzipped when rendered, the Content-Encoding is correctly set to gzip according to LiveHTTPHeaders, and most importantly, the gzipped content is passing the GIDZipTest page (http://www.gidnetwork.com/tools/gzip-te...

Apache as Reverse Proxy for CouchDB

I'm thinking of a web app that uses CouchDB extensively, to the point where there would be great gains from serving with the native erlang HTTP API as much as possible. Can you configure Apache as a reverse proxy to allow outside GETs to be proxied directly to CouchDB, whereas PUT/POST are sent to the application internal logic (for san...

Java Post File to PHP

How can I post a file to a php using java (as a html form would do) ? ...

Good pattern for running automated Selenium tests in HTTP and HTTPS?

Hi, I have a set of Selenium tests which run via HTTP - I'd like to run the same tests under HTTPS aswell as HTTP with as little duplication as possible. I guess other people must already be doing this? I use the Java Selenium Remote Control - but I can probably translate a method from another language. ...

HTTP POST with custom header from iphone to PHP script. How do you read the header?

This code works, and I can see the request go out to my php script through charles with my custom header GUID attached. NSMutableURLRequest *loginRequest = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:feedURLString]]; NSData *myRequestData = [NSData dataWithBytes:[myRequestString UTF8String]length:[myRequestString lengt...

How can I respond to the StatusCode of WebClient before it throws an exception.

We are writing a REST like set of services and we are returning errors as different StatusCodes. In our client application we we prefer if our work flow did not require us to catch and cast an exception to discover the error code. Is there a way to tell the WebClient or HttpWebRequest to stop throwing exceptions when it encounters a S...

How can I get form parameters from HttpListenerRequest?

Hi, I am using a HttpListener to implement a very simple http server, which is accepting a POST from a Java client. When the client calls I get a HttpListenerRequest, which contains all the form parameters. How can I extract the form parameters? I seem to have access only to the content stream.... ...

How do I determine if java connection pooling is working with URLConnection ?

As can be seen in this document, a number of preconditions have to be met before TCP connection pooling "works" in java when using URLConnection. How can I determine if the connections are being pooled ? Are there any objects I can inspect in the sun jdk for this ? ...