Completed
Pull Request — master (#77)
by
unknown
01:18
created

helpers.php ➔ escape_cdata()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
nc 1
nop 1
dl 0
loc 4
rs 10
c 0
b 0
f 0
1
<?php
2
3
if (! function_exists('escape_cdata')) {
4
    /*
5
    * Escape given sequence to remove ending CDATA tags
6
    *
7
    * @param string $value
8
    * @return string
9
    */
10
    function escape_cdata($value)
11
    {
12
        return str_replace(']]>', ']]]]><![CDATA[>', $value);
13
    }
14
}
15