Community Tip - Visit the PTCooler (the community lounge) to get to know your fellow community members and check out some of Dale's Friday Humor posts! X
Hi
I am trying to use a GET http request using a constructed URL which uses differing parameters, fields, values, etc which are passed to it.
"http://"+me.MDSIP+":"+me.MDSPORT+"/"+BinID+"/binevent/"+BinEvent+"/"+BinDate;
I intended on using the ContentLoaderFunctions function to pass the URL but I am struggling to place this value into the url field without errors?
My code is below. currently I receive a http 400 response due to the fact that the url i have in place isnt the variable callurl but the one entered as http://192.168.40.113:80
var calledurl="http://"+me.MDSIP+":"+me.MDSPORT+"/"+BinID+"/binevent/"+BinEvent+"/"+BinDate;
try{
var params = {
proxyScheme: undefined /* STRING */,
headers: undefined /* JSON */,
ignoreSSLErrors: undefined /* BOOLEAN */,
useNTLM: undefined /* BOOLEAN */,
workstation: undefined /* STRING */,
useProxy: undefined /* BOOLEAN */,
withCookies: undefined /* BOOLEAN */,
proxyHost: undefined /* STRING */,
url: "http://192.168.40.113:80" /* STRING */,
timeout: 5 /* NUMBER */,
proxyPort: undefined /* INTEGER */,
password: undefined /* STRING */,
domain: undefined /* STRING */,
username: undefined /* STRING */
};
// result: STRING
var result = Resources["ContentLoaderFunctions"].GetText(params);
}
catch(err)
{
logger.warn(err+" called url is: "+calledurl);
}
any help appreciated
Solved! Go to Solution.
Hi after some analysis I managed to resolve this myself by including the following logic in the url field:
url: "http://"+me.MDSIP+":"+me.MDSPORT+"/"+BinID+"/binevent/"+BinEvent+"/"+BinDate /* STRING */,
Hi after some analysis I managed to resolve this myself by including the following logic in the url field:
url: "http://"+me.MDSIP+":"+me.MDSPORT+"/"+BinID+"/binevent/"+BinEvent+"/"+BinDate /* STRING */,