protected function regexSearchReplace( $html ) {
		$result = $html;
		if ( true === $this->isPbEpub ) {
			// Remove PB created div id (on EPUB201 Export) that will generate a princexml error on re-export
			// @see createPartsAndChapters() in export/epub/class-pb-epub201.php
			$result = preg_replace( '/(?:<div class="chapter+(.*)" id="(.*)">)/isU', '<div>', $result );
			// Remove PB generated content that is superfluous in a WP/PB environment
			// @see createPartsAndChapters() in export/epub/class-pb-epub201.php
			$result = preg_replace( '/(?:<div class="chapter-title-wrap"[^>]*>)(.*)<\/div>/isU', '', $result );
			// Remove PB generated author content to avoid duplicate content, (it's already copied to metadata as pb_section_author )
			$result = preg_replace( '/(?:<h2 class="chapter-author"[^>]*>)(.*)<\/h2>/isU', '', $result );
			// Replace PB generated div class="ugc chapter">
			$result = preg_replace( '/(?:<div class="ugc+(.*)">)/isU', '<div>', $result );
			// Remove PB generated nonindent/indent class
			$result = preg_replace( '/(?:<p class="(.*)+indent">)/isU', '<p>', $result );
		}
		return $result;
	}
protected function regexSearchReplace( $html ) {
		$result = $html;
		if ( true === $this->isPbEpub ) {
			// Remove PB created div id (on EPUB201 Export) that will generate a princexml error on re-export
			// @see createPartsAndChapters() in export/epub/class-pb-epub201.php
			$result = preg_replace( '/(?:<div class="chapter+(.*)" id="(.*)">)/isU', '<div>', $result );
			// Remove PB generated content that is superfluous in a WP/PB environment
			// @see createPartsAndChapters() in export/epub/class-pb-epub201.php
			$result = preg_replace( '/(?:<div class="chapter-title-wrap"[^>]*>)(.*)<\/div>/isU', '', $result );
			// Remove PB generated author content to avoid duplicate content, (it's already copied to metadata as pb_section_author )
			$result = preg_replace( '/(?:<h2 class="chapter-author"[^>]*>)(.*)<\/h2>/isU', '', $result );
			// Replace PB generated div class="ugc chapter">
			$result = preg_replace( '/(?:<div class="ugc+(.*)">)/isU', '<div>', $result );
			// Remove PB generated nonindent/indent class
			$result = preg_replace( '/(?:<p class="(.*)+indent">)/isU', '<p>', $result );
		}
		return $result;
	}
protected function regexSearchReplace ( $ html ) { $ result = $ html ; if ( true === $ this -> isPbEpub ) { // Remove PB created div id (on EPUB201 Export) that will generate a princexml error on re-export // @see createPartsAndChapters() in export/epub/class-pb-epub201.php $ result = preg_replace ( '/(?:<div class="chapter+(.*)" id="(.*)">)/isU' , '<div>' , $ result ) ; // Remove PB generated content that is superfluous in a WP/PB environment // @see createPartsAndChapters() in export/epub/class-pb-epub201.php $ result = preg_replace ( '/(?:<div class="chapter-title-wrap"[^>]*>)(.*)<\/div>/isU' , '' , $ result ) ; // Remove PB generated author content to avoid duplicate content, (it's already copied to metadata as pb_section_author ) $ result = preg_replace ( '/(?:<h2 class="chapter-author"[^>]*>)(.*)<\/h2>/isU' , '' , $ result ) ; // Replace PB generated div class="ugc chapter"> $ result = preg_replace ( '/(?:<div class="ugc+(.*)">)/isU' , '<div>' , $ result ) ; // Remove PB generated nonindent/indent class $ result = preg_replace ( '/(?:<p class="(.*)+indent">)/isU' , '<p>' , $ result ) ; } return $ result ; }
Cleans imported html of unwanted tags

@param string $html

@return string
Cleans imported html of unwanted tags