I have a page with content loaded in vi开发者_如何学Pythona iframe, and the pictures within the content area open up in MilkBox, similar to LightBox. Here's the URL so you can check it out:
http://interplay2010.com/
Under the Media section, the pictures open up within the iframe. I would like the pictures to open up outside the iframe, but I have no idea how to do this.
First of all your page loads much too slow. Try to use compression. You also use 15 external JavaScripts and 7 stylesheets and 20 external background images, thats quite a few HTTP Requests. You also mingle mootools with YUI. Why don't use just one Framework?
Enough nagging, now to your question: The milkbox is set up inside the iFrame, so in order to let the pics popup outside the iFrame you would have to alter Milkbox itself. That is 770 lines of JavaScript. Your best bet is to find the right method inside Milkbox, changing the target of the popUp to its parent frame; that is where the navigation and background picture resides in.
http://interplay2010.com/scripts/gallery/milkbox.js
精彩评论