the problem: us humans can't count as well as robots, so trades are susceptible to human error. lets try to mitigate this error!
the solution: after adding a trade in your etcg, see how many cards are on both sides of the trade
caveats: doesn't work when there are 0 cards on a side (it'll count as there being default 1).
example output:
in your own etcg mods page (if you have one? this is NOT in your normal mods.php file, but within the /etcg/ directory) put this
function tradecardcounter($counttradecards) {
//$counttradecards = trim($counttradecards);
//$counttradecards = stripslashes($counttradecards);
//$counttradecards = htmlspecialchars($counttradecards);
$counttradecards = str_replace(';',',',$counttradecards);
$counttradecards = explode(',',$counttradecards);
$cardcount = count($counttradecards);
echo $cardcount;
}
then within your /etcg/trades.php page, find these and change them
find:
<i class="fa fa-arrow-circle-o-up"></i> Trading Cards
change to:
<i class="fa fa-arrow-circle-o-up"></i> Trading Cards <?php $counttradecards = $row['giving'] ?>(<?php tradecardcounter($counttradecards); ?>)
find:
<i class="fa fa-arrow-circle-o-down"></i> Receiving Cards
change to: