问题
I'm having an issue with Fancybox 2.0 and Internet Explorer. It works fine on all other browsers.
In IE is like the lightbox div comes on top of the iframe and I can't click any buttons.
Also the position in the page is different than on other browsers.
This are the parameters I'm using to call it
$('.fancybutton').fancybox({
type : 'iframe',
maxWidth : 800,
maxHeight : 600,
fitToView : true,
width : '70%',
height : '80%',
autoSize : false,
closeClick : false,
openEffect : 'none',
closeEffect : 'none'
});
Any help would be very much appreciated
I'm opening the iframe with a normal link on an anchor tag
UPDATE
I added the DOCTYPE and the iframe is being opened fine in all browsers but... Inside this iframe i have a number of links, this works as a popup menu. The links are simple anchor tags, but when I click on the links in IE nothing happens. It works perfect on any other browsers :(
Cheers, Federico
回答1:
As it turns out I was missing the DOCTYPE as JFK suggested.
I added it at the top and it now works fine on all browsers
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
Thanks!
来源:https://stackoverflow.com/questions/9565443/fancybox-2-iframe-not-working-correctly-in-ie