Solved

How to change HTTP header info using javascript.

Posted on 2003-12-01
3
5,795 Views
Last Modified: 2009-02-23
Is it possible to add or change the HTTP header info using javascript??

like  the header() function in PHP..whose description is as follows..

header ( string string [, bool replace [, int http_response_code]])

header() is used to send raw HTTP headers. See the HTTP/1.1 specification for more information on HTTP headers.

Or is it possible to make modifications like this using C or any other language.

My problem is i had got a CGI program written in C and when accessed should send a http response code..

Thanks in advance...

0
Comment
Question by:priya1234
3 Comments
 
LVL 5

Accepted Solution

by:
wfRGB earned 125 total points
ID: 9862214
You can't turn a 200 response into a 404 with JS if thats what you are after.

Basic C is a fairly simple to learn so my sugestion is that you get yourself a good book on the subject (and read it)
so that you can rewrite the CGI program.
0
 
LVL 16

Expert Comment

by:jaysolomon
ID: 10393691
No comment has been added lately, so it's time to clean up this TA.
I will leave the following recommendation for this question in the Cleanup topic area:

Accept: wfRGB {http:#9862214}

Please leave any comments here within the next four days.
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

jAy
EE Cleanup Volunteer
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction HTML checkboxes provide the perfect way for a web developer to receive client input when the client's options might be none, one or many.  But the PHP code for processing the checkboxes can be confusing at first.  What if a checkbox is…
Having worked on larger scale sites, we found out that you are bound to look at more scalable solutions to integrating widgets, code snippets or complete applications and mesh them into functional sites, in any given composition. To share some of…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

840 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question