• 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

Creating command to backup MySql database in Laravel

I want to display a sweetalert after the inserting of data in my database

How to get quarter for future date using Carbon?

How do I call Validator from a namespace with an already existing Validator class

PHPExcel How to set conditional formatting to change cell background color based on cells values

No result using makeStyles Material UI in react 18

How can I get user id from session in javascript?

How to generate QR CODE for dynamic generating link and logo using Simple QrCode in laravel?

How to use PHPCBF to fix one issue at a time?

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

loop through an anchor id

Submitting a form with ajax in Wordpress

How can i call a function that executes an fpdf based on the choice of a form selector?

PHP array sort and remove duplicates by two field values

Detect emoticons in string

About Contact Privacy policy Terms and conditions