參考:
vault外掛:http://www.phpbbhacks.com/viewhack.php?id=2379
中文化:http://phpbb-tw.net/phpbb/viewtopic.php ... ight=vault
請先安裝vault外掛
打開vault.php
尋找\r
代碼: 選擇全部
$rsql = "UPDATE " . VAULT_EXCHANGE_USERS_TABLE ."
SET stock_amount = stock_amount + $prize,
stock_price = ".$items[$i]['stock_price']."
WHERE user_id = $user_id
AND stock_id = ".$items[$i]['stock_id'];
代碼: 選擇全部
$rsql = "UPDATE " . VAULT_EXCHANGE_USERS_TABLE ."
SET stock_price = ((stock_price * stock_amount) + (".$items[$i]['stock_price']." * $prize))/(stock_amount + $prize),
stock_amount = stock_amount + $prize
WHERE user_id = $user_id
AND stock_id = ".$items[$i]['stock_id'];