• 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 can i update or reset my password without entering email field in laravel-8?

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

How can I convert from a{a{} b{}} to a[a[],b[]] using php preg_match?

Add Class in html Dynamically in PHP

Could not decode a text frame as UTF-8.

Connecting an HTML webpage to a SQL Server

How to remove from a multidimensional array all duplicate elements including the original?

How to show selected value using javascript in laravel

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

How to check user Permissions using Custom Middleware in Laravel

add " ? " in url via htaccess RewriteRule

How to remove index.php and index from the URL using htaccess | PHP

Unable to get password for the instance created from AMI

Laravel insert dynamic input values with radio button

CodeIgniter force_download is not working

About Contact Privacy policy Terms and conditions