Window.open Invalid Argument Error
So I keep getting an invalid argument error whenever I try to run this script. The error occurs at window.open(url, name, features); Unfortunately I don't know how to fix this.
Solution 1:
The name argument can not have a space in it so the regular expression needs \s
this.getName = function (url) {
name = getAbsolutePath(url);
return name.replace(/[:.\+\/\?\&\=\#\%\-\s]/g, "_").toLowerCase();
};
Solution 2:
We have the code... here is the fix:
var handle = wm.open(url,'I want a name!', 'location=0, menubar=0, resizable=1, scrollbars=1, status=0, toolbar=0, width=' + width + 'px, height=' + height + 'px, top=' + top + 'px , left=' + left + 'px');
Post a Comment for "Window.open Invalid Argument Error"