I am attempting to set the content-type of an asp.net .ashx file to text/plain.
When I run this through the ASP.NET Development Server, the content-type is properly set. When I serve it through IIS7, however, the content-type (and any other header values I set) don't come through (it came through as text/html).
The only value set in ...
I need to access the header to implement methods for a self written client on a mobile phone. The page should be accessible from J2ME without complete Request/Response Headers (Uses less traffic. For Example: J2ME sends only "G i\r\n\r\n"). Is there a way to get this working? (no matter how)
...
I've uploaded an MS powerpoint file to my server, and I'm trying to use Google Docs viewer (http://docs.google.com/viewer) to display it on a webpage.
The file is available here:
http://elgg.wamped.org/test.ppt
If I invoke the docs viewer with the above URL, it is working as expected, see:
http://docs.google.com/viewer?url=http%3A%2F%2...
I have a web application where the requested URL is used in a REST-like fashion. However, if no URL is entered (just the domain) I re-direct to http://www.example.com/home and then my home controller is loaded.
What HTTP status code should I use for this re-direct? This process takes place in my index.php script using a simple header('L...
There is a JSP script for login to a Server. Currently user credentials are being accepted through HTTP Header and the login.jsp file is so designed that once the user provides credentials the user is redirected to a redirectURL which is a fully qualified URL containing Username and Password in query string and hence the user is able to ...
Often I use
Cache-Control: no-cache
or
Cache-Control: max-age=0
The spec says must-revalidate is for max-stale... (the server issue max-stale?)
So if for normal web servers, Apache, or Rails with Mongrels, then I think usually there is no max-stale, so must-revalidate is not needed?
...
I've used Perl a bit for small applications and test code, but I'm new to networking and CGI.
I get how to make the header of a request (using CGI.pm and printing the results of the header() function), but haven't been able to find any info on how to access the headers being sent to my CGI script. Could someone point me in the right dir...
In HTTP there are two ways to POST data: application/x-www-form-urlencoded and multipart/form-data. I understand that most browsers are only able to upload files if multipart/form-data is used. Is there any additional guidance when to use one of the encoding types in an API context (no browser involved)? This might e.g. be based on:
da...
I am trying to understand what the value of X-forwarded-for really means?
By definition, it's value will be of the form: ip1, ip2, .... ipn.
The situation I am thinking of is this-
I am seeing these XFF values at Squid and requests to squid are coming from a CDN. And the CDN is in-turn requesting content on behalf of a user (browser)
M...
Hello,
On one of my sites have a lot of restricted pages which is only available to logged-in users, and for everyone else it outputs a default "you have to be logged in ... " view.
The problem is; a lot of these pages are listed on Google with the not-logged-in-view, and it looks pretty bad when 80% of the pages in the list have the s...
I am developing a Windows application that will live in the system tray. The application can be enabled/disabled by the user.
Whenever the user enables it, it needs to listen/sniff HTTP traffic and add a specific HTTP header on all outgoing packets.
I think it can be done by changing the system or browser settings to be localhost:my_po...
Hello. i did setup like this
but result is still like this . if you tell me where do i make error i appreciate that thank you.
...
Hi,
I'm using IIS 6 and added Cache-Control: no-cache header in IIS management console for entire website. However, when inspecting returned content with fiddler, I still see that Cache-Control: private is sent back to browser along with the response. No Cache-control: no-cache is sent though... Any ideas why?
On the other hand, when I...
<?php $prev_path = "./../../."; $dont_redirect = true; require_once "${prev_path}./config.php";
session_start();
function http_digest_parse($txt){
$needed_parts = array("nonce"=>1, "nc"=>1, "cnonce"=>1, "qop"=>1, "username"=>1, "uri"=>1, "response"=>1);
$data = array();
$keys = implode("|", array_keys($n...
I want to calculate the size in bytes of the http response headers and data in PHP.
Any help would be appreciated
...
The main difference between HTTP/1.0 and HTTP/1.1 is that HTTP/1.1 has a mandatory Host Header in it. (Source: HTTP Pocket Reference - o'reilly)
So, why is that wget, which uses HTTP/1.0 protocol has host header in it?
My Output of wget with netcat
GET / HTTP/1.0
User-Agent: Wget/1.12 (linux-gnu)
Accept: */*
Host: 127.0.0.1:10101
Conn...
Just found that there is a request header authorization. Want to know what is the use of this header. How is it used in the context of jsp tomcat servlet enviornment. How is it different from a normal login module, where user enters username password in a simple jsp page. How a page passes authorization header.
...
If I access my page directly, I get:
$ wget http://localhost:8010/ --save-headers -O -
--2010-10-29 18:30:24-- http://localhost:8010/
Resolving localhost (localhost)... 127.0.0.1
Connecting to localhost (localhost)|127.0.0.1|:8010... connected.
HTTP request sent, awaiting response... 200 OK
Length: 950 [text/html]
Saving to: `STDOUT'
H...
Hi,
Is there any way to work out what a user's name is just by sniffing the NTLM header?
I have an app, that accesses a NTLM auth'd site, and so an Auth prompt opens for the user to authenticate with the site by entering their username / password.
Is there any way, just with access to the headers, to find out what the entered username...
I'm trying to make a sort of PHP bot. The idea is to have to php files, named a.php and b.php. a.php does something, then sleeps 30 seconds, calls b.php, b.php ends the Http request, does some processing, and then calls a.php, which ends the Http request, and so on.
Only problem now is how to end the Http reqest, made using cURL. Ive tr...