500 Error when using Ninja Forms

[ad_1]

@carterlando,

For the 500 error, can you please check your error logs and let me know which PHP error you are receiving? I’ve tried the Ninja Forms free version and there doesn’t appear to be a conflict.

Thanks for the quick reply, Ronald.
I’m on the latest version of WP, PHP 8.2.8
This is the error:

[20-Oct-2023 14:38:30 UTC] PHP Fatal error:  Uncaught TypeError: json_decode(): Argument #1 ($json) must be of type string, array given in C:\Users\Cata\Local Sites\wordpress-default\app\public\wp-content\plugins\ninja-forms\includes\AJAX\Controllers\Submission.php:21

Stack trace:

#0 C:\Users\Cata\Local Sites\wordpress-default\app\public\wp-content\plugins\ninja-forms\includes\AJAX\Controllers\Submission.php(21): json_decode(Array, true)

#1 C:\Users\Cata\Local Sites\wordpress-default\app\public\wp-content\plugins\ninja-forms\ninja-forms.php(294): NF_AJAX_Controllers_Submission->__construct()

#2 C:\Users\Cata\Local Sites\wordpress-default\app\public\wp-content\plugins\ninja-forms\ninja-forms.php(1152): Ninja_Forms::instance()

#3 C:\Users\Cata\Local Sites\wordpress-default\app\public\wp-content\plugins\ninja-forms\ninja-forms.php(1155): Ninja_Forms()

#4 C:\Users\Cata\Local Sites\wordpress-default\app\public\wp-settings.php(462): include_once('C:\\Users\\Cata\\L...')

#5 C:\Users\Cata\Local Sites\wordpress-default\app\public\wp-config.php(110): require_once('C:\\Users\\Cata\\L...')

#6 C:\Users\Cata\Local Sites\wordpress-default\app\public\wp-load.php(50): require_once('C:\\Users\\Cata\\L...')

#7 C:\Users\Cata\Local Sites\wordpress-default\app\public\wp-admin\admin-ajax.php(22): require_once('C:\\Users\\Cata\\L...')

#8 {main}

  thrown in C:\Users\Cata\Local Sites\wordpress-default\app\public\wp-content\plugins\ninja-forms\includes\AJAX\Controllers\Submission.php on line 21

@carterlando

I’ve just released 2.0.14, which should resolve the fatal error.

This error was caused because Ajaxify and Ninja Forms both used the same formData post variable. Since Ninja Forms isn’t expecting the form data it receives, it errors out.

I’ve renamed formData to ajaxifyFormData in order to prevent further conflicts.

If you have a moment, please consider leaving a rating/review.

Thanks,

Ronald

 

This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer