[kune-commits] r1479 - wp-theme/kune

Vicente J. Ruiz Jurado vjrj_ at ourproject.org
Thu Aug 4 11:25:22 CEST 2011


Author: vjrj_
Date: 2011-08-04 11:25:22 +0200 (Thu, 04 Aug 2011)
New Revision: 1479

Modified:
   wp-theme/kune/functions.php
Log:


Modified: wp-theme/kune/functions.php
===================================================================
--- wp-theme/kune/functions.php	2011-08-03 17:07:42 UTC (rev 1478)
+++ wp-theme/kune/functions.php	2011-08-04 09:25:22 UTC (rev 1479)
@@ -494,3 +494,17 @@
 	);
 }
 endif;
+
+/**
+ * http://www.designzzz.com/how-to-stop-wordpress-editor-from-removing-iframe-and-embed-code/
+ */
+function mytheme_tinymce_config( $init ) {
+ $valid_iframe = 'iframe[id|class|title|style|align|frameborder|height|longdesc|marginheight|marginwidth|name|scrolling|src|width]';
+ if ( isset( $init['extended_valid_elements'] ) ) {
+  $init['extended_valid_elements'] .= ',' . $valid_iframe;
+ } else {
+  $init['extended_valid_elements'] = $valid_iframe;
+ }
+ return $init;
+}
+add_filter('tiny_mce_before_init', 'mytheme_tinymce_config');




More information about the kune-commits mailing list