# HG changeset patch # User Matti Hamalainen # Date 1485376782 -7200 # Node ID 01783161eeb21dc6e71bbc27441db6dbe2296b91 # Parent e1cfbfb0b64af3774d49b9783e92c04468315e75 Fix usr and adm ajax and voting. diff -r e1cfbfb0b64a -r 01783161eeb2 admajax.js.php --- a/admajax.js.php Wed Jan 25 22:02:29 2017 +0200 +++ b/admajax.js.php Wed Jan 25 22:39:42 2017 +0200 @@ -13,11 +13,7 @@ // Initiate SQL database connection if (!stConnectSQLDB()) -{ - // Error occured, bail out early - cmPrintPageFooter(); exit; -} // Fetch non-"hardcoded" settings from SQL database stReloadSettings(); diff -r e1cfbfb0b64a -r 01783161eeb2 pages/vote.inc.php --- a/pages/vote.inc.php Wed Jan 25 22:02:29 2017 +0200 +++ b/pages/vote.inc.php Wed Jan 25 22:39:42 2017 +0200 @@ -80,24 +80,7 @@ - + \ No newline at end of file + +?> + +function updateVote(eid, value) +{ + var msuccess = function(txt) + { + } + + var mfail = function(txt) + { + jsMessageBox("

Ooops, an error occured

Something went wrong, votes might not be submitted. :(

"); + } + + jsSendPOSTRequest("action=set&entry_id="+eid+"&vote="+value, msuccess, mfail); + return false; +}