検索

phrase: max: clip:
target: order:
Results of 1 - 10 of about 34 for fruits (0.004 sec.)
配列を昇順にソートする 14108
« sizeof uasort » PHP Manual 配列 関数 配列を昇順にソートする sort (PHP 4, PHP 5, PHP 7, PHP 8) ... 値 常に true を返します。 例 例1 sort() の例 <?php $fruits = array( "lemon" , "orange" , "banana" , "apple" ) ... ; sort ( $fruits ); foreach ( $fruits as $key => $val ) { echo "fru ... $val . "\n" ; } ?> 上の例の出力は以下となります。 fruits[0] = apple fruits[1] = banana fruits[2] = lemon fr ... uits[3] = orange fruits はアルファベットの昇順にソートされました。 例2 sor ...
https://man.plustar.jp/php/function.sort.html - [similar]
ノードの XPath を取得する 12542
« DOMNode::getLineNo DOMNode::hasAttributes » PHP Manual DOMNode ノードの XPath を取得する DOMNo ... ument ; // XML を読み込みます $dom -> loadXML ( ' <fruits> <apples> <apple>braeburn</apple> <apple>granny sm ... apples> <pears> <pear>conference</pear> </pears> </fruits> ' ); // 各要素の XPath を表示します foreach ( $do ... h () . "\n" ; } ?> 上の例の出力は以下となります。 /fruits /fruits/apples /fruits/apples/apple[1] /fruits/app ... les/apple[2] /fruits/pears /fruits/pears/pear 参考 DOMXPath 関連キーワー ...
https://man.plustar.jp/php/domnode.getnodepath.html - [similar]
libxml のエラー処理関数によるエラー処理 11471
« collection.xml および collection.xsl ファイルの例 XSLTProcessor » PHP Manual 例 libxml のエラー ... XSLT の処理中のエラーを捕らえて対応できます。 例1 fruits.xml 妥当な XML ファイルです。 <fruits> <fruit>Appl ... uit> <fruit>Banana</fruit> <fruit>Cherry</fruit> </fruits> 例2 fruits.xsl 無効な select 式が含まれています。 ... ncoding="utf-8" indent="no"/> <xsl:template match="fruits"> <ul> <xsl:apply-templates/> </ul> </xsl:template ... $xsl = new XSLTProcessor (); $xmldoc -> loadXML ( 'fruits.xml' ); $xsldoc -> loadXML ( 'fruits.xsl' ); libxm ...
https://man.plustar.jp/php/xsl.examples-errors.html - [similar]
ユーザー定義の比較関数を使用して、配列を値でソートする 9426
« uksort クラス/オブジェクト » PHP Manual 配列 関数 ユーザー定義の比較関数を使用して、配列を値で ... eturn strcmp ( $a [ "fruit" ], $b [ "fruit" ]); } $fruits [ 0 ][ "fruit" ] = "lemons" ; $fruits [ 1 ][ "frui ... t" ] = "apples" ; $fruits [ 2 ][ "fruit" ] = "grapes" ; usort ( $fruits , "c ... mp" ); foreach ( $fruits as $key => $value ) { echo "\$fruits[ $key ]: " . ... 照を保持しています。 上の例の出力は以下となります。 $fruits[0]: apples $fruits[1]: grapes $fruits[2]: lemons 例 ...
https://man.plustar.jp/php/function.usort.html - [similar]
配列を降順にソートする 8276
« reset shuffle » PHP Manual 配列 関数 配列を降順にソートする rsort (PHP 4, PHP 5, PHP 7, PHP 8) ... 常に true を返します。 例 例1 rsort() の例 <?php $fruits = array( "lemon" , "orange" , "banana" , "apple" ) ... ; rsort ( $fruits ); foreach ( $fruits as $key => $val ) { echo " $k ... なります。 0 = orange 1 = lemon 2 = banana 3 = apple fruits はアルファベットの降順にソートされました。 参考 so ...
https://man.plustar.jp/php/function.rsort.html - [similar]
連想キーと要素との関係を維持しつつ配列を降順にソートする 8212
« array asort » PHP Manual 配列 関数 連想キーと要素との関係を維持しつつ配列を降順にソートする ar ... 常に true を返します。 例 例1 arsort() の例 <?php $fruits = array( "d" => "lemon" , "a" => "orange" , "b" => ... "banana" , "c" => "apple" ); arsort ( $fruits ); foreach ( $fruits as $key => $val ) { echo " $k ... なります。 a = orange d = lemon b = banana c = apple fruits はアルファベットの降順にソートされ、 各要素とキーと ...
https://man.plustar.jp/php/function.arsort.html - [similar]
連想キーと要素との関係を維持しつつ配列を昇順にソートする 8212
« arsort compact » PHP Manual 配列 関数 連想キーと要素との関係を維持しつつ配列を昇順にソートする ... 常に true を返します。 例 例1 asort() の例 <?php $fruits = array( "d" => "lemon" , "a" => "orange" , "b" => ... "banana" , "c" => "apple" ); asort ( $fruits ); foreach ( $fruits as $key => $val ) { echo " $k ... なります。 c = apple b = banana d = lemon a = orange fruits はアルファベットの昇順にソートされ、 各要素とキーと ...
https://man.plustar.jp/php/function.asort.html - [similar]
LimitIterator クラス 7972
« IteratorIterator::valid LimitIterator::__construct » PHP Manual イテレータ LimitIterator クラス ... <?php // 限定した処理を行うイテレータを作成します $fruits = new ArrayIterator (array( 'apple' , 'banana' , ' ... けをループ対象とします foreach (new LimitIterator ( $fruits , 0 , 3 ) as $fruit ) { var_dump ( $fruit ); } ech ... まり、0 は apple です foreach (new LimitIterator ( $fruits , 2 ) as $fruit ) { var_dump ( $fruit ); } ?> 上の ...
https://man.plustar.jp/php/class.limititerator.html - [similar]
配列の全ての要素にユーザー定義の関数を適用する 7924
« array_walk_recursive array » PHP Manual 配列 関数 配列の全ての要素にユーザー定義の関数を適用す ... るようになりました。 例 例1 array_walk() の例 <?php $fruits = array( "d" => "lemon" , "a" => "orange" , "b" => ... item2 \n" ; } echo "Before ...:\n" ; array_walk ( $fruits , 'test_print' ); array_walk ( $fruits , 'test_alt ... 'fruit' ); echo "... and after:\n" ; array_walk ( $fruits , 'test_print' ); ?> 上の例の出力は以下となります。 ...
https://man.plustar.jp/php/function.array-walk.html - [similar]
配列をキーで降順にソートする 7860
« key ksort » PHP Manual 配列 関数 配列をキーで降順にソートする krsort (PHP 4, PHP 5, PHP 7, PHP ... 常に true を返します。 例 例1 krsort() の例 <?php $fruits = array( "d" => "lemon" , "a" => "orange" , "b" => ... "banana" , "c" => "apple" ); krsort ( $fruits ); foreach ( $fruits as $key => $val ) { echo " $k ...
https://man.plustar.jp/php/function.krsort.html - [similar]
PREV 1 2 3 4 NEXT