note 11590 deleted from function.explode by jimw

From: Date: Fri, 07 Dec 2001 21:23:03 +0000
Subject: note 11590 deleted from function.explode by jimw
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-22003@lists.php.net to get a copy of this message
A little obvious, but I'll save those interested the few seconds. To get only the last element of an explode function, you don't have to assign its count to anything. Simply use: $value = $array[count($array) - 1];

« previous php.notes (#22003) next »