jQuery post problem
<p>Could anybody help with this? </p>

<p>I am trying to integrate a coupon function into the order process on my website using jQuery to post the coupon code used and check the coupon code used exists in my database. However jQuery post will not work correctly. Here is my code.</p>

<pre><code>jQuery(function () {
    jQuery("#discount-code").click(function () {
        var coupon = jQuery("#CouponCode").val();
        if (coupon) {
            alert("Coupon Used");
            jQuery.ajax({
                success: function (data) {
                    if (data) {
                        alert("DATA RECEIVED");
                    }
                },
                data: 'coupon=' + coupon,
                type: 'POST',
                dataType: 'json',
                url: 'http://example.com/process-coupon.php'
            });
        }
        return false;
    });
});
</code></pre>

<p>I am getting the coupon used alert but after that nothing. I am not even seeing the post info in firebug.</p>

<p>Can anybody see the problem here?</p>
