• 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

advanced custom fields wordpress custom class

Pages are working fine on localhost but not running on the hosting server

How to delete old images from public folder on update using Laravel

zsh: command not found: php

WordPress ACFNotice: get_field() - We've detected one or more calls to retrieve ACF field values before ACF has been initialized

Using Associative arrays

PHP: set a (deep) array key from an array [closed]

How to get median and quartiles/percentiles of an array in JavaScript (or PHP)?

How to install ZeroMQ for PHP on an Alpine Linux container?

401 Unauthorized only occurring on some pages in Laravel 8

Make Shipping Method fields Mandatory on Woocommerce checkout page

How to send parameters in soap request in php in __soapcall() function

Update Total in checkout of Woocommerce with Ajax Request

How to fix this error : Ask your hosting provider to use PHP 7.2.5 or higher for both HTTP and CLI?

Could not decode a text frame as UTF-8.

About Contact Privacy policy Terms and conditions