Hi all,
Spent the best part of a few hours searching the forum for an answer but nothing seems to have helped me fix/answer my problem.
As the title states, Im trying to display the contents from a div from another page within the same site, in a shadowbox on a page.
I have an image map on Page_One.html. When a user clicks on a 'hotspot' I want the shadowbox to open and display the contents of a particular div in Page_Two.html.
Is this at all possible? I have the image map working just displaying a basic image, and I have the inline content one setup displaying the contents of a div which is on the same page - just cant get it to display div content from another page. Below are some code snippets; if anyone can see something wrong in these snippets then please let me know. If not, then I will try sort out a live example.
<script type="text/javascript">
window.onload = function(){
var o = {
players: ['html', 'iframe'],
loadingImage: '
http://landscapedesign.cyberstore.co.nz/csmods/js/images/loading.gif',
counterType: 'skip'
};
Shadowbox.init(o);
// setup image map demo
Shadowbox.setup(document.getElementById('Map').getElementsByTagName('area'));
};
</script>
### Page One (Main page) ###
<iimg height="331" alt="" width="500" usemap="#Map" border="0" src="/userfiles/image/test_image.jpg" /> <map id="Map" name="Map">
<area href="Page_Two.html#PUOne" coords="190,62,240,101" shape="RECT" />
<area href="/userfiles/image/test_image.jpg" coords="314,219,393,263" shape="RECT" />
<area href="#" coords="32,56,107,104" shape="RECT" /></map>
<p><aa class="option" title="Inline content" target="_top" rel="shadowbox;width=200;height=400" href="Page_Two.html#PUOne">Other Page</p>
<p><aa class="option" title="Inline content" target="_top" rel="shadowbox;width=200;height=400" href="Page_One.html#PUTwo">This Page</p>
<div class="hidden" id="PUTwo">
<div id="inline-sample-content" style="padding-right: 20px; padding-left: 20px; padding-bottom: 20px; padding-top: 20px">
<p>THIS PAGE THIS PAGE</p>
</div>
</div>
I hope this is clear and makes sense. I have intentionally added a couple of stray chars in the code above so it displays. If anymore info is needed just let me know. Thanks in advance!