• 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

AJAX call fails with SyntaxError: Unexpected end of JSON input

javascriptphpjqueryajax


PHP Snippet 1:

var data = {};
 data['rawFiles'] =$('#projectIDs').val(); 
 data['metadata'] = $('#getData').val();
  data['type']=  $('#submitType').val();
  data['pid']='csv';
   data['command']='data/qcTest'

PHP Snippet 2:

$.ajax({type: "POST", url: posturl, data: JSON.stringify(data), dataType: 'json'})

Related Snippets

PHP contact form configuration [duplicate]

Script @php artisan package:discover handling the post-autoload-dump event returned with error code 255

how to identify the web server name of remote host

How can I stop a symfony process which is listening on http://127.0.0.1:8000

oauth-private.key does not exist or is not readable

Doctrine ORM: Excluding Records Based on Values of Nested Relationships

PHP array slice from position + attempt to return fixed number of items

Nginx disallowing execution of PHP in uploads directory with Magento

Submitting a form with ajax in Wordpress

Why does using salted hash on python and php give me different results?

yii2 and mssql insert varbinary into model

java URL working on browser but not in client program

How to submit a form when page loads using JavaScript?

Send same name multiple checkbox values via ajax

How to fix Call to undefined method AppModelsTableName::factory?

About Contact Privacy policy Terms and conditions