forms - jQuery Submit Post Data Not Changing -
i'm checking data in form jquery. however, while incoming data in form having trouble.
not refreshing data in following code
$("#registerform").submit(function () { $.post("dogrula.php", $("#registerform").serialize(), function (data) { var hata = data; if (hata == "wrong number") { alert("yanlış"); return false; } }); return false; });
the full code
<script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js"> </script> <script type="text/javascript"> $(document).ready(function () { $("#bd_year").focusout(function () { $.post("dogrula.php", $("#registerform").serialize(), function (data) { $("#charnum").text(data).css({ "color": "green", "font-size": "120%", "margin-left": "30%" }); }); return false; }); $("#registerform").submit(function () { $.post("dogrula.php", $("#registerform").serialize(), function (data) { var hata = data; if (hata == "wrong number") { alert("wrong number"); return false; } }); return false; }); $("#cfield_6").keyup(function () { var max = 11; var len = $(this).val().length; if (len >= max) { $("#charnum").text(" sayı limiti doldu").css({ "color": "red", "font-size": "120%", "margin-left": "30%" }); } else { var char = max - len; $("#charnum").text(char + " sayı kaldı").css({ "color": "black", "font-size": "120%", "margin-left": "30%"}); } }); }); </script>
$_post or data messages:
wrong code, true code, not finding, sorry english bad,i hope right recounted
i not sure if got question right, might want try disable caching:
$.ajaxsetup({ cache: false });
Comments
Post a Comment