• 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

PHP password_verify

Login if user is active using Laravel Breeze

How can I make this nested location configuration use the correct path to call a php program?

how to sort by a custom appended relation to model

Best way to scrolldown onpageload

WooCommerce Additional Information - if empty, hide

How to prevent phpmailer sending embedded image as an attachment on Gmail?

Open a popup box after receiving result from ajax

Uncaught TypeError: Cannot read property 'length' of null when retrieving tags from wp

Sum array values

How to execute sql code based on fetch array

MOODLE: What does it mean to aggregate h5p assets?

protect my blog content

disable two buttons after clicking another button

PHP mail sending empty mails

About Contact Privacy policy Terms and conditions