Possible Duplicate:
What does $k => $v in foreach($ex as $k=>$v) mean?
I am trying to understand what this means:
foreach($this->domains as $domain=>$users) {
// some code...
}
I understand $this->domains
is an array that foreach
will index over. But what does as $domain=>$users
mean? I have only seen the =>
operator used in an array to set (key, value) pairs. The class has a member called $domain
, but I assume that would be accessed as $this->domain
.