Jump to content

Embed a Wordpress / Formidable Forms view


Giray

Recommended Posts

Thoughts welcome (this one is above my pay grade).

I have a Wordpress site running Formidable Forms. I want to embed a 'view' into an Invision page. This is the code they give me (I've replaced what needed replacing) but still no go. I pasted it into as page html and also tried as a custom block. The form view does not appear.

Off hand, does anyone see anything that jumps off the page?

On another post, I read something about how jquery loads?

Thoughts?

Thanks so much for any help.

 

<div id="frmapi-ENTER-ID-HERE" class="frmapi-form" data-url="httpS://YOURSITE.com/wp-json/frm/v2/views/ENTER-ID-HERE?return=html"></div>
<script type="text/javascript">
jQuery(document).ready(function($){
var frmapi=$('.frmapi-form');
if(frmapi.length){
	for(var frmi=0,frmlen=frmapi.length;frmi<frmlen;frmi++){
		frmapiGetData($(frmapi[frmi]));
	}
}
});
function frmapiGetData(frmcont){
	jQuery.ajax({
		dataType:'json',
		url:frmcont.data('url'),
		success:function(json){
			frmcont.html(json.renderedHtml);
		}
	});
}
</script>

 

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...