Javascript var inside another var

Viewed 57

I'm JS novice, My problem is that I have a var resortuid its value is from PHP (it's working). I need to open a json file with resortuid in link. In other words I need to replace XXXX in url with resortuid var. I'm sure that it is a banal question, but not for me.
EDIT: codefrom first response is working on SO, but not in TYPO3 fluid template, my new question is how to pass it to fluid template?

var resortuid = '1125';
var settings = {  
    "url": "https://aaa.aa/XXXX_simple.json",
    "method": "GET",
    "timeout": 0,
};
1 Answers
Related