views:

428

answers:

4
           'display the left product image
           if intImagePos = 2 then
              response.write("<td class=""ProductImage"">" & vbcrlf)
              'show image
              if Len(objProduct.Image2) > 0 then
                 response.write("<a class=""thumbnail"" href=""javascript: void(0)"" onclick=""MM_openBrWindow('images/festool/KAPEXKS120-571287/KAPEXKS120-571287-Gallery/','scrollbars=no,resizable=no,width=840,height=580')""><img src=" & objProduct.Image1 & " border=""0""><br>See gallery of this product</a>")
              else
                 response.write("<p>No Picture Available</p>")
              end if
              response.write("</td>")
           end if

Error code in IE is:

Line: 28 Char: 3 Error: Invalid argument. Code: 0

Line 28 is:

  var newWindow = window.open(theURL,winName,features+win_position);

Thanks for any help in solving this matter, I'm not a programmer at all and have no idea what I'm looking at, just copy and pasting and manipulating text to try and get stuff to work how I want.

+1  A: 

This is just a guess, but I recall having a problem with window.open in ie where the winName variable had a space in it. Maybe put an alert(winName) before it to check.

Andrew
Quite likely... IE will fail if the window name has spaces or tabshttp://webbugtrack.blogspot.com/2008/06/bug-289-popup-window-name-cant-have.html
scunliffe
A: 

You might want to watch the error in Firefox's javascript debugger:

https://addons.mozilla.org/en-US/firefox/addon/216

Firefox often fails silently on javascript errors. So it might not be an IE only issue.

Keltex
A: 

The error is not in your server-side code. I'd look for the problem after the page is rendered.

Chris Ballance
+1  A: 

Your call to MM_openBrWindow() only has two parameters, but it takes three. Try changing it to this:

MM_openBrWindow('images/festool/KAPEXKS120-571287/KAPEXKS120-571287-Gallery/','putsomenamehere','scrollbars=no,resizable=no,width=840,height=580');
John Sheehan
Doh! this is the issue, there is no window name.
scunliffe
This worked, thank you very much.
USteppin