473,407 Members | 2,598 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,407 software developers and data experts.

Creating an authorization header

67
What I'm doing requires me to set an authorization header in order to get information from the site. Is it possible to set an authorization header in javascript? If so, how? The actual text explaining it, though poorly, on google code is such:

After a successful authentication request, use the Auth value to create an Authorization header for each request:

Authorization: GoogleLogin auth=yourAuthValue

I am able to get the Auth value, but I don't know what to do with it.

Someone please help,
Person
Jul 11 '07 #1
5 5717
acoder
16,027 Expert Mod 8TB
Is this an Ajax request?
Jul 12 '07 #2
Person
67
Yes, it's part of an Ajax GET request.
Jul 12 '07 #3
acoder
16,027 Expert Mod 8TB
Use the Ajax object's setRequestHeader method:
Expand|Select|Wrap|Line Numbers
  1. xmlhttp.setRequestHeader("Authorization","GoogleLogin...");
Jul 13 '07 #4
Person
67
Thank you very much, that helped.
Jul 13 '07 #5
acoder
16,027 Expert Mod 8TB
Thank you very much, that helped.
Glad you got it working.
Jul 14 '07 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: phreeskier | last post by:
i want to implement authorization with windows authentication and don't have the slightest clue of how to do this implementation. the basic windows authentication for this .NET application is...
0
by: Chris | last post by:
Hi all, I'm having trouble setting an authorization cookie from a web service. I need to set an authorization cookie on the client machine when the proper soap header is sent with...
2
by: Andrea | last post by:
I'm having some difficulty creating a report in Access and I need some suggestions. My company issues "Return Authorizations" when customers need to return products. A customer calls in and we...
15
by: Shaun Wilde | last post by:
I am not sure if this is a .NET bug/feature and IIS5 one or a combination of the 2 so here goes I have a situation where when I call an ASP.NET webservice running under windows 2000 (I assume...
4
by: tshad | last post by:
I am trying to set up an Image authorization where you type in the value that is in a picture to log on to our site. I found a program that is supposed to do it, but it doesn't seem to work. ...
2
by: Ottavio | last post by:
Hello, I'm having some problems with the authentication during a web service call I know I have to add the "Authorization: Basic xxxxxxxx" in the http header (not soap header) but I can't find a...
5
by: MIUSS | last post by:
I tried many things for several hours to repair this code but I didn't get success:-( The code below is from some learning site which is little old. I didn't change anything in there, I know it's...
5
by: dabei | last post by:
Hi, I am trying to use AS3 to make a URL request with authorization header. Using the code below: var request:URLRequest = new URLRequest ( 'http://myserviceURL' ); var...
9
by: AGP | last post by:
My project uses a Webbroswer control to navigate to certain websites and do some processing on the info found there. However, my company has a proxy server which I must authenticate through to get...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.