Home Ajax script does not update DOM
Reply: 0

Ajax script does not update DOM

user964 Published in March 23, 2018, 8:59 am

I have a little Ajax script that executes a POST and returns the result on screen. I debugged the script and I can see that the POST is successful, however I cannot get the result displayed on screen. It looks like I need an extra refresh or something. Any ideas what's wrong?

Thanks in advance Regards

$(document).ready(function() {

    $("#vehicleMessages").submit(function(event) {



function ajaxPost() {

    var form = $("#vehicleMessages");

        type: "POST",
        contentType: "application/json",
        url: form.attr("action") + "?tripId=" + $("#tripId").val() + "&partitionKey=" + $("#partitionKey").val(),
        dataType: 'json',
        success: function(result) {
            if (result.status == "Done") {
                $("#postResult").html("Result: " + result.data);
You need to login account before you can post.

About| Privacy statement| Terms of Service| Advertising| Contact us| Help| Sitemap|
Processed in 0.423881 second(s) , Gzip On .

© 2016 Powered by mzan.com design MATCHINFO