I have a file as an array:

$list = file('views.php.dat');

Contents looks like:
something
something
something_else
another
something
another

I am sorting the array so everything is together (not sure if this is necessary for what I am trying).

My goal is output something like this:
something (3times)
something_else (1time)
another (2times)

I know I can use array_uniq() to remove duplicates, but I would like to find them and count them, if the value doesn't appear more than once it'll be given the value '1'

Any direction on this will be appreciated .... Please be gentle with the assumed knowledge ... I'm new (3 days) to php.

-Chris

    That appears to have done what I'm looking for.... thanks!
    Now just for the "me being anal about the way the output looks" part of my adventure... hehe

      Now the output looks like this.... which is great! ..... just have to strip it a little further to something that I can work with if I add more to the code later. Thanks again

      output:
      Array ( [value] => 4 [something] => 3 [another] => 1 )

        Write a Reply...