The following code snippet illustrates an example of embedding content from YouJizz using an iFrame:
frameborder : This attribute specifies the presence of a border around the iframe. A value of 0 means there will be no border.
In this example:
An older internet explorer compatibility attribute designed to allow the background color of the parent page to show through the iframe document if the source content has no background color specified. Modern Best Practices for Media Embedding
: These fixed pixel dimensions dictated the exact size of the video player. Fixed sizing creates major display issues on mobile screens. The following code snippet illustrates an example of
: Ensure that the embedded content is appropriate and does not lead to any legal or reputational issues.
: Instead of fixed width and height , consider making your iframe responsive. This can be achieved with CSS, using width: 100% and a wrapper element, or by using aspect-ratio preserving techniques. Modern Best Practices for Media Embedding : These
: The src attribute specifies the URL of the page that should be embedded. In this case, http://www.youjizz.com/videos/embed/205618 . This URL points to a specific video embed link on YouJizz, a website known for adult content.
<div style="position: relative; padding-bottom: 56.25%;"><iframe src="https://www.youjizz.com/videos/embed/205618" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%;" scrolling="no" allowtransparency="true"> </iframe></div> : Instead of fixed width and height ,