• 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

Use Python plotly chart in PHP

get folder directory from input type file - PHP

PHP rotate matrix counter-clockwise

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

"Mixed content blocked" when running an HTTP AJAX operation in an HTTPS page

PHP Warning: Module already loaded in Unknown on line 0

PHP if in_array() how to get the key as well?

Laravel excel maatwebsite 3.1 import, date column in excel cell returns as unknown format number. How to solve this?

Combine multiple columns into an array as one of the key in a results set

Failing validation doesn't stop code execution in livewire component

Reload parent page after submit in iframe

Custom post type single page not working

wordpress : How to specify the cause "This site can’t be reached"

Post Form Data To phpmyadmin Database

PHP Deprecated issue when running artisan command

About Contact Privacy policy Terms and conditions