By default wordpress removes iframe tags from posts. This is not always the desired behavior as youtube, vimeo and other widgets are added via iframes.
The filtering of iframe tags is performed on the clientside by the javascript editor tinymce as well as on the serverside by the wordpress whitelist filter. Therefor, to disable iframe filtering, it is neccessary to add two hooks to either a plugin or the functions.php of your theme:
Disable iframe filtering in tinymce
Simply add the following code to your functions.php – this adds iframes as valid elements for tinymce:
add_filter('tiny_mce_before_init', create_function('$a', '$a["extended_valid_elements"] = "iframe[id|class|align|frameborder|height|name|scrolling|src|width|title|style]";return $a;'));
Disable server-side iframe filtering
Add this code to your functions.php – it adds iframes to the whitelist of wordpress:
global $allowedposttags;
$allowedposttags["iframe"] = array("id" => array(),"class" => array(), "align" => array(),"frameborder" => array(),"title" => array(),"style" => array(),"name" => array(),"scrolling" => array(),"src" => array(),"height" => array(),"width" => array());