Lines Matching refs:offset
75 * @param int $offset number of UTF-8 characters offset (from left)
82 public static function substr($str, $offset, $length = null) argument
86 return mb_substr($str, $offset);
89 return mb_substr($str, $offset, $length);
108 $offset = (int)$offset;
113 if ($offset < 0 && $length < 0 && $length < $offset) return '';
119 if ($offset < 0) {
121 $offset = $strlen + $offset;
122 if ($offset < 0) $offset = 0;
126 if ($offset > 0) {
127 $Ox = (int)($offset / 65535);
128 $Oy = $offset % 65535;
141 if ($offset > $strlen) return ''; // another trivial case
145 $length = min($strlen - $offset, $length);
152 if ($length < ($offset - $strlen)) return '';
348 * @param integer $offset
354 public static function strpos($haystack, $needle, $offset = 0) argument
359 while ($length === null || $length < $offset) {
360 $pos = strpos($haystack, $needle, $offset + $comp);
367 if ($length < $offset)