Lines Matching refs:v

130         foreach ($option as $k => $v) {
133 switch ($v) {
137 $this->_api_encoding = $v;
140 $this->_error('Set Parameter: Unknown parameter '.$v.' for option '.$k);
145 $this->_allow_overlong = ($v) ? true : false;
148 $this->_strict_mode = ($v) ? true : false;
192 foreach ($arr as $k => $v) {
193 if (preg_match('!^'.preg_quote($this->_punycode_prefix, '!').'!', $v)) {
194 $conv = $this->_decode($v);
200 foreach ($arr as $k => $v) {
201 if (preg_match('!^'.preg_quote($this->_punycode_prefix, '!').'!', $v)) {
202 $conv = $this->_decode($v);
217 foreach ($arr as $k => $v) {
218 $conv = $this->_decode($v);
232 foreach ($arr as $k => $v) {
233 $conv = $this->_decode($v);
234 $arr[$k] = ($conv) ? $conv : $v;
291 foreach ($decoded as $k => $v) {
293 switch($v) {
432 foreach ($decoded as $k => $v) {
433 if ($v > 0x7a) {
570 foreach ($input as $v) {
572 if (in_array($v, $this->NP['map_nothing'])) continue;
575 if (in_array($v, $this->NP['prohibit']) || in_array($v, $this->NP['general_prohibited'])) {
576 $this->_error('NAMEPREP: Prohibited input U+'.sprintf('%08X', $v));
580 if ($range[0] <= $v && $v <= $range[1]) {
581 $this->_error('NAMEPREP: Prohibited input U+'.sprintf('%08X', $v));
587 if (0xAC00 <= $v && $v <= 0xD7AF) {
588 foreach ($this->_hangul_decompose($v) as $out) {
592 } elseif (isset($this->NP['replacemaps'][$v])) {
593 foreach ($this->_apply_cannonical_ordering($this->NP['replacemaps'][$v]) as $out) {
597 $output[] = (int) $v;
796 $v = ord($input[$k]); // Extract byte from input string
798 if ($v < 128) { // We found an ASCII char - put into stirng as is
799 $output[$out_len] = $v;
808 $start_byte = $v;
811 if ($v >> 5 == 6) { // &110xxxxx 10xxxxx
813 $v = ($v - 192) << 6;
814 } elseif ($v >> 4 == 14) { // &1110xxxx 10xxxxxx 10xxxxxx
816 $v = ($v - 224) << 12;
817 } elseif ($v >> 3 == 30) { // &11110xxx 10xxxxxx 10xxxxxx 10xxxxxx
819 $v = ($v - 240) << 18;
820 } elseif ($v >> 2 == 62) { // &111110xx 10xxxxxx 10xxxxxx 10xxxxxx 10xxxxxx
822 $v = ($v - 248) << 24;
823 } elseif ($v >> 1 == 126) { // &1111110x 10xxxxxx 10xxxxxx 10xxxxxx 10xxxxxx 10xxxxxx
825 $v = ($v - 252) << 30;
831 $output[$out_len] = (int) $v;
839 if (($v < 0xA0 && $start_byte == 0xE0) || ($v < 0x90 && $start_byte == 0xF0) || ($v > 0x8F && $start_byte == 0xF4)) {
844 if ($v >> 6 == 2) { // Bit mask must be 10xxxxxx
845 $v = ($v - 128) << ($next_byte * 6);
846 $output[($out_len - 1)] += $v;
869 foreach ($input as $v) {
871 // $v = ord($v);
872 if ($v < 128) { // 7bit are transferred literally
873 $output .= chr($v);
874 } elseif ($v < (1 << 11)) { // 2 bytes
875 $output .= chr(192 + ($v >> 6)) . chr(128 + ($v & 63));
876 } elseif ($v < (1 << 16)) { // 3 bytes
877 $output .= chr(224 + ($v >> 12)) . chr(128 + (($v >> 6) & 63)) . chr(128 + ($v & 63));
878 } elseif ($v < (1 << 21)) { // 4 bytes
879 $output .= chr(240 + ($v >> 18)) . chr(128 + (($v >> 12) & 63))
880 . chr(128 + (($v >> 6) & 63)) . chr(128 + ($v & 63));
881 } elseif ($v < (1 << 26)) { // 5 bytes
882 $output .= chr(248 + ($v >> 24)) . chr(128 + (($v >> 18) & 63))
883 . chr(128 + (($v >> 12) & 63)) . chr(128 + (($v >> 6) & 63))
884 . chr(128 + ($v & 63));
885 } elseif ($v < (1 << 31)) { // 6 bytes
886 $output .= chr(252 + ($v >> 30)) . chr(128 + (($v >> 24) & 63))
887 . chr(128 + (($v >> 18) & 63)) . chr(128 + (($v >> 12) & 63))
888 . chr(128 + (($v >> 6) & 63)) . chr(128 + ($v & 63));
907 foreach ($input as $v) {
908 $output .= chr(($v >> 24) & 255).chr(($v >> 16) & 255).chr(($v >> 8) & 255).chr($v & 255);