Re: Array numeric key -> alpha key replacement

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



----- Original Message ----- From: <scotdiddle@xxxxxxxxxxxxxxxxxx>
To: <php-general@xxxxxxxxxxxxx>
Sent: Wednesday, December 05, 2007 1:00 PM
Subject:  Array numeric key -> alpha key replacement


Hello All,

Is the a built-in PHP call that I am overlooking which lets me replace key values in an array.

$inputArray = array(0 => array, 1 => array); (generated programtically)

   I want to end up with :

   $newArray = array('FAF1' => array, 'ODM1' => array);

    Thanks.

Scot L. Diddle, UPS Freight, Richmond VA

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



What about:

$inputArray = array();
$inputArray['FAF1'] = array();
$inputArray['ODM1'] = array();
print_r($inputArray);

HTH, Cor
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux