AS3CF_Filter::process_content PHP Метод

process_content() защищенный Метод

Process content.
protected process_content ( string $content, array $cache, array &$to_cache ) : mixed
$content string
$cache array
$to_cache array
Результат mixed
    protected function process_content($content, $cache, &$to_cache)
    {
        if (empty($content)) {
            // Nothing to filter, return
            return $content;
        }
        if (!$this->should_filter_content()) {
            // Not filtering content, return
            return $content;
        }
        $content = $this->pre_replace_content($content);
        // Find URLs from img src
        $url_pairs = $this->get_urls_from_img_src($content, $to_cache);
        $content = $this->replace_urls($content, $url_pairs);
        // Find leftover URLs
        $content = $this->find_urls_and_replace($content, $cache, $to_cache);
        // Perform post processing if required
        $content = $this->post_process_content($content);
        return $content;
    }