最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

Why does using conditional logic in gravity forms break the form when placed using php

programmeradmin1浏览0评论

I have a form built using gravity forms...

I am placing this form onto my page using PHP like this...

// set our form ID 'Order Checkout'
$form_id = 1;

// enqueue the necessary styles and scripts into head
gravity_form_enqueue_scripts($form_id,true);

...

// place my form onto page
gravity_form($form_id,false,true,false,null,true);


This works nicely and submits nicely...


But then when I apply conditional logic to a field, which validates and saves ok. The output on the page is this...


Form appears missing.

But in the inspector you can see all the scripts/styles and the form html have loaded ok, but for some reason on #gform_wrapper_1 it has style="display:none;" applied to it.

If remove the inline style, all the conditional logic fields are visible and the conditional logic doesn't work.

Absolutely no console errors.

Any ideas why I might be seeing this. Thanks

发布评论

评论列表(0)

  1. 暂无评论