| @@ -2,9 +2,9 @@ | ||
| 2 | 2 | if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly |
| 3 | 3 | |
| 4 | 4 | class autoptimizeHTML extends autoptimizeBase { |
| 5 | 5 | private $keepcomments = false; |
| 6 | - private $exclude = array('<!-- ngg_resource_manager_marker -->', '<!--noindex-->', '<!--/noindex-->'); | |
| 6 | + private $exclude = array('<!-- ngg_resource_manager_marker -->'); | |
| 7 | 7 | |
| 8 | 8 | public function read($options) { |
| 9 | 9 | // Remove the HTML comments? |
| 10 | 10 | $this->keepcomments = (bool) $options['keepcomments']; |
| @@ -63,14 +63,8 @@ | ||
| 63 | 63 | $replString="<!--noptimize-->".$exclString."<!--/noptimize-->"; |
| 64 | 64 | if (strpos($this->content,$replString)!==false) { |
| 65 | 65 | $this->content=str_replace($replString,$exclString,$this->content); |
| 66 | 66 | } |
| 67 | - } | |
| 68 | - | |
| 69 | - // revslider data attribs somehow suffer from HTML optimization, this fixes that | |
| 70 | - if ( class_exists('RevSlider') && apply_filters('autoptimize_filter_html_dataattrib_cleanup', false) ) { | |
| 71 | - $this->content = preg_replace('#\n(data-.*$)\n#Um',' $1 ', $this->content); | |
| 72 | - $this->content = preg_replace('#<[^>]*(=\"[^"\'<>\s]*\")(\w)#','$1 $2', $this->content); | |
| 73 | 67 | } |
| 74 | 68 | |
| 75 | 69 | return true; |
| 76 | 70 | } |