- if(isset($_POST['submit']) && $_POST['mnumber']!="") {
- $db->query("UPDATE students SET blackboard=blackboard+1 WHERE mnumber=" . trim($_POST['mnumber']));
- block("lightgreen", "added blackboard");
+ if($_GET['mnumber']!="") {
+ // would be better to store timestamp in blackboard db!
+ if( time()-$_GET['tstamp'] < 5 ) {
+ $db->query("UPDATE students SET blackboard=blackboard+1 WHERE mnumber=" . trim($_GET['mnumber']));
+ block("lightgreen", "added blackboard");
+ }