Jump to content

Echo values of array within a while loop?


lynxus

Recommended Posts

Hi guys,

 

I have a array with country codes and then how many hits form that country.

 

How do i echo eahc bit in  while loop?

 

Ive tried:

foreach ($IpCount as $a) {

echo "$a";

echo "<br>";

}

 

However this for instance will just echo teh value, but not the key.

 

Im really rubbish with arrays and no amount of googling is helping ( Mainly because im not sure on the question )

 

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.