I'm developing a new experimental web-application framework, and I decided to give RESTful some attention. I've read up on the basics, and feel like I have a pretty good understanding of RESTful as a concept.
I've got a system up and running, using URLs strictly to define 'nouns' in the system and take the 'verbs' from the HTTP request ...
We are running ASP.NET MVC on IIS6. We have started to notice a problem with IE8 clients.
Almost all the time, the ContentType returned is 'text/html' but occasionally, it will be returned as 'application/xhtml+xml'. This is causing IE8 to try and download the file instead of rendering the contents in the browsers.
I can't find any re...
I've got an existing WAR file that is not developed by me. I deploy the application to the Tomcat server and after that it is accessible for everybody. Which is not good. I need to restrict the access to the context with HTTP Basic auth. What is the best way to do that? I do not need any sophisticated user management system I just need a...
Not sure if this is possible in a single .htacess file, but ideally, I'd like to have:
http://example.com redirect to: http://www.example.com
https://example.com redirect to: https://www.example.com
And anything that is http://whatever.example.com NOT append the www like http://www.whatever.example.com.
Is this possible?
Thanks,
D....
Let's say I have a calendar on my page and clicking on a day would mark that day as complete.
But I want to use POST and not GET, since GET is not suitable for this kind of stuff (changing something). And I also don't want to use JavaScript.
What I'm going for here is to build a page that will work without JavaScript (which I will use t...
I have a binary value being URL Encoded, and then POSTed to an HttpServlet. The following code shows how I first attempted to extract this data. Very simple except that the result is a String, not bytes.
This seemed to work at first, except that an extra byte appeared three bytes from the end. What I eventually figured out was that my d...
Hello all,
I'm trying to do something I thought would be relatively simple: Upload an image to a server with the Android SDK. I'm found a lot of example code:
http://groups.google.com/group/android-developers/browse_thread/thread/f9e17bbaf50c5fc/46145fcacd450e48
http://linklens.blogspot.com/2009/06/android-multipart-upload.html
But n...
Is it possible to filter HTTPs traffic?
For example via a TDI filter? Or perhaps you need to use a proxy?
This product seems to do filtering of HTTPS traffic and I'd like to know how it does it, as well as if this is the only way.
How about via the Windows Filtering Platform for Vista and up?
...
I would like to make an HTTP/S proxy program to filter/deny certain http traffic based on how I parse the HTTP request in C++.
Is there some kind of starting point code that I can use with an open license for commercial use?
For example if I wanted to do a project on searching I would start with lucene.
...
How do you go about redirecting a browser and sending a HTTP POST request in PHP? A header("Location: file.php?foo=bar") of HTTP POST requests, if you will.
...
I have a web application. I am using C#. I have existing methods in my API for various things but all only submit and return bool/int/strings.
All of my API methods have the directive
System.ServiceModel.OperationContract
All the parameters are of
System.Runtime.Serialization.DataMember
I would like to be able to receive a poste...
A friend and I are currently working on a turn-based game with chat with both desktop browser and Android clients, with Google App Engine as the server.
We're using the Java API for GAE and using HTTP for communication with the server. We've implemented simple chat functionality, and we're getting undesirable latencies 1-3 seconds from...
Hello,
I am programming a software in Python to download HTTP PDF from a database.
Sometimes the download stop with this message :
retrieval incomplete: got only 3617232 out of 10689634 bytes
How can I ask the download to restart where it stops using the 206 Partial Content HTTP feature ?
I can do it using wget -c and it works pret...
After searching a lot, reading every tutorials I've found and asking some questions here, I've finally managed to answer corrctly (at least I think) to if-none-match and if-modified-since HTTP requests.
To do a quick recap, this is what I do on every pages cacheable:
session_cache_limiter('public'); //Cache on clients and proxies
sessi...
In Jersey, how can we 'replace' the status string associated with a known status code?
e.g.
return Response.status(401).build();
generates a HTTP response that contains:
HTTP/1.1 401 Unauthorized
I (not me, but the client application) would like to see the response as:
HTTP/1.1 401 Authorization Required
I tried the following a...
I would like to return a custom HTTP status code from a RESTful WCF web service when a certain condition is met. I do not want to use the standard HTTP status codes. I would like to maybe return a 514 status code which means something to the calling user. Is this even possible WebOperationContext.Current.OutgoingResponse?
...
Howdy,
I'm playing with HTTP Basic Authorization. As we all know, when a client gets a 401 error on requesting a page, the client must collect authorization credentials from the users (typically in the form of a pop-up window).
Subsequent requests for resources under that part of the URL will be accompanied by "Authorization: Basic...
Hi all,
Does HTTP PUT have advantages over HTTP POST, particularly for File Uploads? Data transfer should be highly secure.. Your ideas / guidance on this will be of great help.
regards,
Kingsley Reuben
...
import httplib
def httpCode(theurl):
if theurl.startswith("http://"): theurl = theurl[7:]
head = theurl[:theurl.find('/')]
tail = theurl[theurl.find('/'):]
response_code = 0
conn = httplib.HTTPConnection(head)
conn.request("HEAD",tail)
res = conn.getresponse()
response_code = int(res.status)
return res...
Very simple.
>>> import socket
>>> socket.gethostbyname('http://yahoo.com')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
socket.gaierror: [Errno -2] Name or service not known
...