Code Duplication    Length = 2-3 lines in 4 locations

class/curl.php 1 location

@@ 90-91 (lines=2) @@
87
		curl_setopt($this->mSh, CURLOPT_HTTPGET, true);
88
89
		// Remove endding '?" of url
90
		if ('?' == substr($url, -1, 1))
91
			$url = substr($url, 0, strlen($url - 1));
92
93
		// Char used between url & param
94
		if (false === strpos($url, '?'))

class/doc-markdown.php 1 location

@@ 201-202 (lines=2) @@
198
		if (!empty($ar)) {
199
			foreach ($ar as $v) {
200
				$s_t = Markdown($v);
201
				if ('<p>' == substr($s_t, 0, 3))
202
					$s_t = trim(substr($s_t, 3, strlen($s_t) - 8));
203
				$s_copyright2 .= "<li>" . $s_t . "</li>\n";
204
			}
205
		}

class/mvc-view.php 1 location

@@ 309-310 (lines=2) @@
306
		}
307
308
		// Remove tailing '/'
309
		if ('/' == substr($key, -1))
310
			$key = substr($key, 0, strlen($key) - 1);
311
312
		return $key;
313
	} // end of func CacheKey

src/Fwlib/Net/Curl.php 1 location

@@ 76-78 (lines=3) @@
73
        curl_setopt($handle, CURLOPT_HTTPGET, true);
74
75
        // Remove tailing '?" from url
76
        if ('?' == substr($url, -1, 1)) {
77
            $url = substr($url, 0, strlen($url) - 1);
78
        }
79
80
        // Char used between url & param
81
        $linker = (false === strpos($url, '?')) ? '?' : '&';