已知数组arr,现在需要标题栏按照月循环,假如从17年1月至18年12月。假如数组arr中的confirm_m项和标题的月相同时,则显示数组arr中的confirm_m项对应confirm_value的值。
比如confirm_m为1804,则显示成这种形式:
1801 1802 1803 1804 1805 1806 ...
- - - 50484 -
请问怎么写?
数组arr:
array(26) {
[0]=>
string(2) "b0"
["area2"]=>
string(2) "b0"
[1]=>
string(18) "A项目"
["project"]=>
string(18) "A项目"
[2]=>
string(2) "PE"
["department"]=>
string(2) "PE"
[3]=>
string(4) "1804"
["confirm_m"]=>
string(4) "1804"
[4]=>
string(1) " "
["confirm_m_2"]=>
string(1) " "
[5]=>
string(1) " "
["confirm_m_3"]=>
string(1) " "
[6]=>
string(1) " "
["confirm_m_4"]=>
string(1) " "
[7]=>
string(1) " "
["confirm_m_5"]=>
string(1) " "
[8]=>
float(50484)
["confirm_value"]=>
float(50484)
[9]=>
float(0)
["confirm_value_2"]=>
float(0)
[10]=>
float(0)
["confirm_value_3"]=>
float(0)
[11]=>
float(0)
["confirm_value_4"]=>
float(0)
[12]=>
float(0)
["confirm_value_5"]=>
float(0)
}