• 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

Facebook PHP SDK - will not logout properly

how to hide previous markers when new markers added in google map javascript api

Destroy session upon refresh

Laravel get user data with profile

PHP file_get_contents function

PHPUnit gives error: Target [IlluminateContractsViewFactory] is not instantiable

Using spatie/media-library, how to rename a collection of uploaded files?

How to reset Laravel AuthManager/guards in between API calls in tests?

Can't remotely connect to MySQL error (13) with PHP script, connecting through CLI works

PHP Startup: Unable to load dynamic library 'openssl' in Ubuntu

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

php mysql + create a friend request system

google content api for shopping

protect images from being copied

Problems getting instance of UploadedFile in Yii2

About Contact Privacy policy Terms and conditions