Jump to content

[SOLVED] Wrong Output


The Little Guy

Recommended Posts

Why is this giving me a result of 0?

 

 

<?php 
$uniqV = array_count_values($weekDay);
$show = array();
$gvals = '';
foreach($weekDays as $day){
	if(!in_array($day,$show)){
		array_push($show,$day);
		$radCol = array_rand($chartColors);
		$gval = '<set name="'.$day.'" value="'.$uniqV[$day].'" color="'.$chartColors[$radCol].'" />';
	}
	$gvals += $gval;
}
echo $gvals;
?>

 

I echo out $gvals, and the value I get is 0 why?

 

I am expecting some HTML.

Link to comment
https://forums.phpfreaks.com/topic/75860-solved-wrong-output/
Share on other sites

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.