• 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

Laravel Multi-language routes without prefix

How to display MySQL table using php and edit it in a web browser

onKeyUp event calculation not working on the following rows from php generated forms except the first one

How to Display Data in Yajra Datatables Laravel 7?

How to assert parameter attribute sub-structures in PHPUnit mock call expectations

Pagekite error: FAIL: localhost:8080 is down

Exact alternate to mcrypt_encrypt in PHP 7.2

Currently Using CodeIgniter Framework i have an Error

Google Calendar API batch request PHP

get folder directory from input type file - PHP

How can I remove the "Advanced" panel of all blocks in WordPress block editor?

Trying to iterate over a mongodb cursor twice - failing

How to increase the PHP upload limits [duplicate]

Laravel display validation error

How to change HTML structure inside WP <head>

About Contact Privacy policy Terms and conditions