Format code comments
This commit is contained in:
parent
8d102a8d1e
commit
d20eb20f30
1 changed files with 2 additions and 2 deletions
|
@ -13,7 +13,7 @@
|
|||
// Find and save the aspect ratio for all iframes
|
||||
$iframes.each(function () {
|
||||
$( this ).data( "ratio", this.height / this.width )
|
||||
// Remove the hardcoded width & height attributes
|
||||
// Remove the hardcoded width and height attributes
|
||||
.removeAttr( "width" )
|
||||
.removeAttr( "height" );
|
||||
});
|
||||
|
@ -21,7 +21,7 @@
|
|||
// Resize the iframes when the window is resized
|
||||
$( window ).resize( function () {
|
||||
$iframes.each( function() {
|
||||
// Get the parent container's width
|
||||
// Get the parent container's width
|
||||
var width = $( this ).parent().width();
|
||||
$( this ).width( width )
|
||||
.height( width * $( this ).data( "ratio" ) );
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue