/** * Fix annoying characters that the user probably didn't do on purpose * * @param string $html * * @return string|void */ function fixAnnoyingCharacters($html) { // Do parent first $html = parent::fixAnnoyingCharacters($html); // EPUB specific // Adobe Digital Editions has problems with exotic dashes, that is to say if this were 1999... // TODO: Some users want this, others do not want this, make up your mind... // $html = str_replace( array( '–', '–', '—', '—', '‑' ), '-', $html ); return $html; }