Alex Hogan wrote:

Hi All,

I am looking through the manual and I think I may be blind or something, but
how can I create an associative array from two arrays.
What I have is two arrays that look like this;

Array1([0]=>Spider, [1]=>Monkey, [2]=>Cards)
Array2([0]=>26.3, [1]=>0.65, [2]=>62.07)

I want to combine them into;

ArrayCombined([Spider]=>26.3, [Monkey]=>0.65, [Cards]=>62.07)

So I can compare it to a third array.

TIA

alex




****************************************************************** The contents of this e-mail and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom it is addressed. The views stated herein do not necessarily represent the view of the company. If you are not the intended recipient of this e-mail you may not copy, forward, disclose, or otherwise use it or any part of it in any form whatsoever. If you have received this e-mail in error please e-mail the sender. ******************************************************************




Well, if you use PHP5 you could use this function:
(probably not an option now, but good to know for the future)

http://us4.php.net/manual/en/function.array-combine.php

Gabe

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



Reply via email to