Searched refs:pad_length (Results 1 – 7 of 7) sorted by relevance
/php-src/ext/standard/tests/strings/ |
H A D | str_pad_variation2.phpt | 15 0, // pad_length < sizeof(input_string) 16 9, // pad_length <= sizeof(input_string) 17 10, // pad_length > sizeof(input_string) 18 16, // pad_length > sizeof(input_string) 23 /*loop through to use each variant of $pad_length on 25 foreach ($pad_lengths as $pad_length ) { 27 var_dump( bin2hex( str_pad($string, $pad_length) ) ); 29 var_dump( bin2hex( str_pad($string, $pad_length, $pad_string) ) ); 30 var_dump( bin2hex( str_pad($string, $pad_length, $pad_string, STR_PAD_LEFT) ) ); 31 var_dump( bin2hex( str_pad($string, $pad_length, $pad_string, STR_PAD_RIGHT) ) ); [all …]
|
H A D | str_pad.phpt | 11 $pad_length = 20; 15 var_dump( str_pad($input_string, $pad_length, $pad_string, STR_PAD_LEFT) ); 16 var_dump( str_pad($input_string, $pad_length, $pad_string, STR_PAD_RIGHT) ); 17 var_dump( str_pad($input_string, $pad_length, $pad_string, STR_PAD_BOTH) ); 34 0, // pad_length < sizeof(input_string) 35 9, // pad_length <= sizeof(input_string) 36 10, // pad_length > sizeof(input_string) 37 16, // pad_length > sizeof(input_string) 43 foreach ($pad_lengths as $pad_length ) { 55 $pad_length = 16; [all …]
|
H A D | str_pad_variation5.phpt | 2 Test str_pad() function : usage variations - unexpected large value for '$pad_length' argument 14 /* Test str_pad() function: with unexpected inputs for '$pad_length' 18 echo "*** Testing str_pad() function: with large value for for 'pad_length' argument ***\n"; 22 $pad_length = PHP_INT_MAX - 16; /* zend_string header is 16 bytes */ 23 var_dump( str_pad($input, $pad_length) ); 27 *** Testing str_pad() function: with large value for for 'pad_length' argument ***
|
H A D | str_pad_variation1.phpt | 2 Test str_pad() function : usage variations - large values for '$pad_length' argument 11 /* Test str_pad() function: with unexpected inputs for '$pad_length' 15 echo "*** Testing str_pad() function: with large value for for 'pad_length' argument ***\n"; 33 *** Testing str_pad() function: with large value for for 'pad_length' argument ***
|
H A D | stristr_variation2.phpt | 50 //defining '$pad_length' argument 51 $pad_length = "20";
|
/php-src/ext/mbstring/ |
H A D | mbstring.c | 5847 size_t pad_length = mb_get_strlen(pad, encoding); in PHP_FUNCTION() local 5869 size_t full_left_pad_copies = left_pad / pad_length; in PHP_FUNCTION() 5870 size_t full_right_pad_copies = right_pad / pad_length; in PHP_FUNCTION() 5871 size_t remaining_left_pad_chars = left_pad % pad_length; in PHP_FUNCTION() 5872 size_t remaining_right_pad_chars = right_pad % pad_length; in PHP_FUNCTION()
|
/php-src/ext/standard/ |
H A D | string.c | 5738 zend_long pad_length; /* Length to pad to */ local 5750 Z_PARAM_LONG(pad_length) 5758 if (pad_length < 0 || (size_t)pad_length <= ZSTR_LEN(input)) { 5772 num_pad_chars = pad_length - ZSTR_LEN(input);
|
Completed in 39 milliseconds