Categories > TinyButStrong general >

Associative array key

The forum is closed. Please use Stack Overflow for submitting new questions. Use tags: tinybutstrong , opentbs
By: cow
Date: 2004-08-08
Time: 12:45

Associative array key

Hi!

Can I access the associative array , current key?
example:
$array=array("key1"=>"value1","key2"=>"value2");
...
$engine->MergeBlock("blk",$array);
...

[blk.keyname] => [blk.[keyname]]

So I want to print out the current item key.
Any idea?
Cow
By: Skrol29
Date: 2004-08-08
Time: 14:38

Re: Associative array key

If the array has not sub-array, just like your example. Then the following should work:

[blk.key] => [blk.val]