mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-08-12 12:50:28 +00:00
WP oEmbed: Improve height attribute sanitization
Props afercia, swissspidy. Fixes #34527. git-svn-id: https://develop.svn.wordpress.org/trunk@35478 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -31,14 +31,14 @@
|
||||
|
||||
/* Resize the iframe on request. */
|
||||
if ( 'height' === data.message ) {
|
||||
height = data.value;
|
||||
height = parseInt( data.value, 10 );
|
||||
if ( height > 1000 ) {
|
||||
height = 1000;
|
||||
} else if ( height < 200 ) {
|
||||
} else if ( ~~height < 200 ) {
|
||||
height = 200;
|
||||
}
|
||||
|
||||
source.height = (height) + 'px';
|
||||
source.height = height;
|
||||
}
|
||||
|
||||
/* Link to a specific URL on request. */
|
||||
|
||||
Reference in New Issue
Block a user