Questions about Iframe and Video Player display covered/Wbox custom close Function

Source: Internet
Author: User

1. Video Player masking

The parent page is the video player page. When you open the window wbox to select the video file to be played, you will find that the opening page is covered by the broadcaster, imitating youku. When you play the video, click the login window to open the window, modify your issue.

Solution: When opening a window, hide the Div of the video player and open the window. After closing the window, display the Div of the parent page. During this period, the custom wbox function is disabled. See the following summary.

Second, Wbox User-Defined Function Shutdown

Find wbox. add the onclick event in the following code section of js, and then customize the close function FunBoxclose () on the parent page of the pop-up window. First execute the operation you want, and then call the close method of Wbox.

Wbox. js Code

1 <td width = "20px" title = "close"> <div class = "wBox_close" onclick = "parent. FunBoxclose ()">

Parent page:

View Code of the parent page

1 // close the pop-up window 2 function FunBoxclose () 3 {4 write all the operations you have performed this time, such as hiding DIV5 $ ("# DivPlayer") with the ID DivPlayer "). show (); 6 // close the window (the method provided by Wbox) 7 parent. iframewbox. close (); 8 9}

 

Finally:

To sum up, let's take a closer look at the implementation of large websites and analyze the js library as appropriate.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.