Well... a winning bug? PHPcodevar_dump ($ sumArr ['trade _ CLOSED ']); $ sumValue = array_sum ($ sumArr); var_dump ($ sumArr ['Trad... A bug like winning?
PHP code
var_dump($sumArr['TRADE_CLOSED']);$sumValue = array_sum($sumArr);var_dump($sumArr);var_dump($sumArr['TRADE_CLOSED']);
Result:
Int 3
Array (size = 4)
'Wait _ SELLER_SEND_GOODS '=> int 8
'Wait _ BUYER_CONFIRM_GOODS '=> int 37
'Wait _ BUYER_PAY '=> int 2
'Trade _ CLOSED '=> & int 50
Int 50
This is character? Is this a bug? What's your sister's problem?
I used a temporary file to re-write a small piece of code for testing, but the output was normal...
------ Solution --------------------
Why is TRADE_CLOSED a reference?
------ Solution --------------------
PHP code
$ SumArr = Array ('wait _ SELLER_SEND_GOODS '=> 8, 'Wait _ BUYER_CONFIRM_GOODS' => 37, 'Wait _ BUYER_PAY '=> 2, 'trade _ CLOSED '=> 50,); var_dump ($ sumArr ['trade _ CLOSED']); $ sumValue = array_sum ($ sumArr); var_dump ($ sumArr ); var_dump ($ sumArr ['trade _ CLOSED ']);
------ Solution --------------------
PHP code
8,'WAIT_BUYER_CONFIRM_GOODS' =>37,'WAIT_BUYER_PAY' =>2,'TRADE_CLOSED'=>&$aa,);var_dump($sumArr['TRADE_CLOSED']);$sumValue = array_sum($sumArr);var_dump($sumArr);var_dump($sumArr['TRADE_CLOSED']);