Reputation: 7651
url: '/folder/file' + i + '.js',
The above url creates file1.js, file2.js etc etc
I want the url to be : /foldename +file[i] + i + '.js'
Can i have an array file which would control the names of the file being created.
Upvotes: 0
Views: 80
Reputation: 2398
Uh... Yeah, actually you can:
var file = Array();
file[0] = 'file';
file[1] = 'otherfilename';
/* ... */
var url = '/folder/' + file[j] + i + '.js';
Upvotes: 2