| @@ 44-50 (lines=7) @@ | ||
| 41 | // Pass string to Smallworld_cleanup_string |
|
| 42 | function Smallworld_cleanup($text) |
|
| 43 | { |
|
| 44 | if (is_array($text)) { |
|
| 45 | foreach ($text as $key => $value) { |
|
| 46 | $text[$key] = Smallworld_cleanup_string($value); |
|
| 47 | } |
|
| 48 | } else { |
|
| 49 | $text = Smallworld_cleanup_string($text); |
|
| 50 | } |
|
| 51 | ||
| 52 | return $text; |
|
| 53 | } |
|
| @@ 68-74 (lines=7) @@ | ||
| 65 | // or send string to Smallworld_sanitize_string |
|
| 66 | function Smallworld_sanitize($text) |
|
| 67 | { |
|
| 68 | if (is_array($text)) { |
|
| 69 | foreach ($text as $key => $value) { |
|
| 70 | $text[$key] = Smallworld_sanitize_string($value); |
|
| 71 | } |
|
| 72 | } else { |
|
| 73 | $text = Smallworld_sanitize_string($text); |
|
| 74 | } |
|
| 75 | ||
| 76 | return $text; |
|
| 77 | } |
|