• Categories
    • PHP
    • phpMyAdmin
    • PHPMailer
    • FFMpeg
    • PHPEXcel
    • PHPDoc
    • PHPUnit
    • CakePHP
    • CakePHP 2.0
    • Cake PHP 2.1
    • CakePHP Model
    • Facebook PHP SDK
    • composer-php
    • PHP 7
    • PHP GD
    All Categories
  • About

JQuery content editable div and text box on submit not sending POST

javascriptphpjqueryhtmltext-editor


PHP Snippet 1:

$(document).ready(function() {
    $("#save").on("click", function(event) {
        var formData = {text: $("#editor").html(), name: $("#name").val()};
        event.preventDefault();
        $.ajax({
            url: 'freewordsave.php',
            type:'POST',
            data: formData,
            success: function(msg)
            {
                alert('Your file was saved!');
            }
        });
    });
});

Related Snippets

Get keys from associative array [duplicate]

NGINX: connect() to unix:/var/run/php7.2-fpm.sock failed (2: No such file or directory)

Confirm Leave on External Links in Wordpress

Is it possible to change the table name in the migration file-laravel

Currently Using CodeIgniter Framework i have an Error

Render the content of default_filter.php in Joomla front-end

Laravel csrf token mismatch for ajax POST Request

str_word_count() function doesn't display Arabic language properly

Submitting a form with ajax in Wordpress

How To Access A Column In M-M Relationship Table In Laravel

Remove product downloads section in woocommerce email notifications

How to edit Records using CodeIgniter

Implode columnar values between two arrays into a flat array of concatenated strings

Docker image build with PHP zip extension shows "bundled libzip is deprecated" warning

How to MODIFY a Google Docs document via API using search-and-replace?

About Contact Privacy policy Terms and conditions