• 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

How do I upload a laravel project on cPanel shared hosting?

Debugging Stripe Webhook Event

PHP Get value from JSON [duplicate]

How to find the date a user created their Google account

Add bold text and line break into Laravel Notification Email

Display Link Title Instead of URL in XSL

Download & Save Zoom Recording in directory by PHP

Need to display only array value in JSON output

Custom API and cunsuming in php?

Laravel: Create morphs() relationship nullable

Issue saving card for customer

Do I need to install `fxp/composer-asset-plugin` if I'm not doing front-end development

How can I create a Download Page with post php method?

Python - Include another Python script

Why does array_map() with null as callback create an "array of arrays"?

About Contact Privacy policy Terms and conditions