From: Steve Sutton Date: Thu, 9 Jun 2016 15:40:54 +0000 (-0400) Subject: Adding filter to keep gravity forms from creating post entries X-Git-Tag: v1.0.9^2 X-Git-Url: http://cvs2.gaslightmedia.com/gitweb/index.cgi?a=commitdiff_plain;h=64aea93c4d2eddfa684c014bc5feacbcadd37cb0;p=WP-Themes%2Fshipwreckmuseum.git Adding filter to keep gravity forms from creating post entries If we we custom fields they will create a post entry. This will keep any form from adding one. --- diff --git a/functions.php b/functions.php index 1a24888..88636b1 100644 --- a/functions.php +++ b/functions.php @@ -388,5 +388,8 @@ function glm_per_product_rates_only( $rates, $package ) { return $rates; } - +add_filter( 'gform_disable_post_creation', 'disable_post_creation', 10, 3 ); +function disable_post_creation( $is_disabled, $form, $entry ) { + return true; +} ?>