66866
asked on
How to call an external httphandler using Jquery
Here's my situation
I have a customer facing website that show's customer information. I would like to get the user id (through a handler) using a jquery call so that i can capture that information for web analytics. the javascript file does not belong to the same project as the customer. in the traditional examples, i have seen where the request to a handler takes place within the same project. however in my situation i want to know how can i call the handler outside of the project. I have attached the code that i am currently using. everytime the return is 'undefined'
Any quick response would be very much appreciated.
I have a customer facing website that show's customer information. I would like to get the user id (through a handler) using a jquery call so that i can capture that information for web analytics. the javascript file does not belong to the same project as the customer. in the traditional examples, i have seen where the request to a handler takes place within the same project. however in my situation i want to know how can i call the handler outside of the project. I have attached the code that i am currently using. everytime the return is 'undefined'
Any quick response would be very much appreciated.
function getGUID(customerurl) {
var handler = "http://" + customerurl + '/userguidhandler.ashx?callback=?';
$.getJSON(handler, function (getData) {
return getData;
});
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
. http://www.ibm.com/developerworks/library/wa-aj-jsonp1/