PHP
downloads | documentation | faq | getting help | mailing lists | reporting bugs | php.net sites | links | conferences | my php.net

search for in the

ArrayObject::offsetGet> <ArrayObject::getIterator
Last updated: Fri, 03 Oct 2008

view this page in

ArrayObject::offsetExists

(PHP 5)

ArrayObject::offsetExists要求された $index が存在するかどうかを返す

説明

bool ArrayObject::offsetExists ( mixed $index )
警告

この関数は、 現在のところ詳細な情報はありません。引数のリストのみが 記述されています。

パラメータ

index

調べたいインデックス。

返り値

指定した $index が存在する場合に TRUE、それ以外の場合に FALSE を返します。



add a note add a note User Contributed Notes
ArrayObject::offsetExists
goran at extensionsforjoomla dot com
09-Jul-2007 12:52
In versions prior to PHP 5.2.2 offsetExists() would return false if index value is null.
<?php
// running PHP 5.2.1
$params = new ArrayObject(array('INT'=>null, 'STR'=> null, 'BOOL'=>null, 'LOB'=>null));
$test = $params->offsetExists('INT');
var_dump($test);
// result would be bool(false)
// running PHP 5.2.2
$params = new ArrayObject(array('INT'=>null, 'STR'=> null, 'BOOL'=>null, 'LOB'=>null));
$test = $params->offsetExists('INT');
var_dump($test);
// result would be bool(true)
?>
Both tests where made on Windows platform.

ArrayObject::offsetGet> <ArrayObject::getIterator
Last updated: Fri, 03 Oct 2008
 
 
show source | credits | sitemap | contact | advertising | mirror sites