Code Duplication    Length = 5-5 lines in 8 locations

manager/includes/document.parser.class.inc.php 8 locations

@@ 1354-1358 (lines=5) @@
1351
                $value = $this->applyFilter($value, $modifiers, $key);
1352
            }
1353
1354
            if (strpos($content, $s) !== false) {
1355
                $content = str_replace($s, $value, $content);
1356
            } elseif($this->debug) {
1357
                $this->addLog('mergeDocumentContent parse error', $_SERVER['REQUEST_URI'] . $s, 2);
1358
            }
1359
        }
1360
1361
        return $content;
@@ 1522-1526 (lines=5) @@
1519
                $value = $this->applyFilter($value, $modifiers, $key);
1520
            }
1521
            $s = &$matches[0][$i];
1522
            if (strpos($content, $s) !== false) {
1523
                $content = str_replace($s, $value, $content);
1524
            } elseif($this->debug) {
1525
                $this->addLog('mergeSettingsContent parse error', $_SERVER['REQUEST_URI'] . $s, 2);
1526
            }
1527
        }
1528
        return $content;
1529
    }
@@ 1591-1595 (lines=5) @@
1588
            }
1589
1590
            $s = &$matches[0][$i];
1591
            if (strpos($content, $s) !== false) {
1592
                $content = str_replace($s, $value, $content);
1593
            } elseif($this->debug) {
1594
                $this->addLog('mergeChunkContent parse error', $_SERVER['REQUEST_URI'] . $s, 2);
1595
            }
1596
        }
1597
        return $content;
1598
    }
@@ 1650-1654 (lines=5) @@
1647
                $value = $this->applyFilter($value, $modifiers, $key);
1648
            }
1649
            $s = &$matches[0][$i];
1650
            if (strpos($content, $s) !== false) {
1651
                $content = str_replace($s, $value, $content);
1652
            } elseif($this->debug) {
1653
                $this->addLog('mergePlaceholderContent parse error', $_SERVER['REQUEST_URI'] . $s, 2);
1654
            }
1655
        }
1656
        return $content;
1657
    }
@@ 1861-1865 (lines=5) @@
1858
        foreach ($matches[1] as $i => $v) {
1859
            $v = str_ireplace($sTags, $rTags, $v);
1860
            $s = &$matches[0][$i];
1861
            if (strpos($content, $s) !== false) {
1862
                $content = str_replace($s, $v, $content);
1863
            } elseif($this->debug) {
1864
                $this->addLog('ignoreCommentedTagsContent parse error', $_SERVER['REQUEST_URI'] . $s, 2);
1865
            }
1866
        }
1867
        return $content;
1868
    }
@@ 2018-2022 (lines=5) @@
2015
                } else {
2016
                    $value = $s;
2017
                }
2018
                if (strpos($content, $s) !== false) {
2019
                    $content = str_replace($s, $value, $content);
2020
                } elseif($this->debug) {
2021
                    $this->addLog('evalSnippetsSGVar parse error', $_SERVER['REQUEST_URI'] . $s, 2);
2022
                }
2023
                continue;
2024
            }
2025
            $value = $this->_get_snip_result($call);
@@ 2030-2034 (lines=5) @@
2027
                continue;
2028
            }
2029
2030
            if (strpos($content, $s) !== false) {
2031
                $content = str_replace($s, $value, $content);
2032
            } elseif($this->debug) {
2033
                $this->addLog('evalSnippets parse error', $_SERVER['REQUEST_URI'] . $s, 2);
2034
            }
2035
        }
2036
2037
        if ($this->dumpSnippets) {
@@ 4371-4375 (lines=5) @@
4368
                }
4369
                $value = $this->applyFilter($value, $modifiers, $key);
4370
            }
4371
            if (strpos($tpl, $s) !== false) {
4372
                $tpl = str_replace($s, $value, $tpl);
4373
            } elseif($this->debug) {
4374
                $this->addLog('parseText parse error', $_SERVER['REQUEST_URI'] . $s, 2);
4375
            }
4376
        }
4377
4378
        return $tpl;