Please do not send a form letter!
I need an Expert in Javascript for this and future work.
Thanks.
———-
Need custom javascript written called app.js. When app.js is called it will interpret the variables passed to it.
Example:
app.js?app.js?id=____&ca=____&cc=___&r=___&d=___
id is the filename that will be called, example:
app.js?app.js?id=1234
Would call 1234.js as a document.write
If variable ca is defined, then it need to use this variable as a directory, example:
app.js?app.js?id=1234&ca=1
Would call /ca1/1234.js as a document.write
If cc is defined, then check the cookie for the countrycode or run the url provided to get the country code. (I will provide the url and sample code on how cc is checked.)
If cc=1 and country code is US, run the javascript. If cc=1 and country code is NOT US, do not run the javascript. If cc=1 and country is NOT US and variable d is defined, call variable d.js
Example: app.js?app.js?id=1234&ca=1&cc=1&d=888
Would call /ca1/1234.js as a document.write if countrycode=US
If country code is NOT US it would call /ca1/888.js
If r is defined as 1 it should insert allow a random number to be used and insert this after the filename. Example: app.js?app.js?id=1234&ca=1&cc=1&r=1
Would call /ca1/1234.js?r=RANDOM# as a document.write if countrycode=US