From 56ca1d6050c5fc1cb0a9c7b4302a9a8811c1034a Mon Sep 17 00:00:00 2001 From: Eric Rasmussen <erasmussen2@unl.edu> Date: Mon, 18 Oct 2010 22:45:32 +0000 Subject: [PATCH] Use WDN.post rather than $.ajax --- www/physics/ribbon_cutting2010/voting.php | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/www/physics/ribbon_cutting2010/voting.php b/www/physics/ribbon_cutting2010/voting.php index fb7d5fe..a5dea80 100644 --- a/www/physics/ribbon_cutting2010/voting.php +++ b/www/physics/ribbon_cutting2010/voting.php @@ -35,19 +35,18 @@ WDN.jQuery(function($) { $(".vote").click(function() { var parent = $(this); $(this).fadeIn(200).html('...'); - $.ajax({ - type: "POST", - url: "castvote.php", - data: 'id=' + $(this).attr("id"), - cache: false, - success: function(html){ + WDN.post( + "castvote.php", + 'id=' + $(this).attr("id"), + function(html){ parent.html(html); parent.removeClass('vote red'); parent.addClass('green'); parent.unbind('click'); $(".vote").slideToggle("fast"); - } - }); + }, + '' + ); return false; }); }); -- GitLab