Hi all,
When setting a style at #inline2 hiding it, Fancybox will appear empty on click. In addition the #inline2 element can be seen in Fancybox when there's no style hiding it. Though this example is copy'ed directly from the various examples on the official Fancybox site. See Various Examples at http://fancybox.net/home.
Someone please enlighten me, and tell me what I'm doing wrong! I obviously only want the #inline2 element to be shown in Fancybox, and not as a regular part of my page.
Thanks in advance
/The guy having spend hours on what should be an easy job!
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html lang="da">
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<link type="text/css" href="/css/jquery.fancybox-1.3.1.css" rel="stylesheet" />
<script type="text/javascript" src="/js/jquery-1.4.2.min.js"></script>
<script type="text/javascript" src="/js/jquery.fancybox-1.3.1.js"></script>
<script type="text/javascript">
jQuery(document).ready(function() {
$("#various2").fancybox({
'modal' : true,
'transitionIn' : 'fade',
'transitionOut' : 'fade'
});
});
</script>
</head>
<body>
<a id="various2" href="#inline2">Inline - modal window</a>
<div id="inline2" style="display:none;">
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit.</a></p>
</div>
</body>
</html>