You are here

function simple_html_dom::restore_noise in simplehtmldom API 6

Same name and namespace in other branches
  1. 5.2 simplehtmldom/simple_html_dom.php \simple_html_dom::restore_noise()
  2. 7 simplehtmldom/simple_html_dom.php \simple_html_dom::restore_noise()
2 calls to simple_html_dom::restore_noise()
simple_html_dom::parse_attr in simplehtmldom/simple_html_dom.php
simple_html_dom::read_tag in simplehtmldom/simple_html_dom.php

File

simplehtmldom/simple_html_dom.php, line 944

Class

simple_html_dom

Code

function restore_noise($text) {
  while (($pos = strpos($text, '___noise___')) !== false) {
    $key = '___noise___' . $text[$pos + 11] . $text[$pos + 12] . $text[$pos + 13];
    if (isset($this->noise[$key])) {
      $text = substr($text, 0, $pos) . $this->noise[$key] . substr($text, $pos + 14);
    }
  }
  return $text;
}