Iframe/code snippet form that can be used on other sites and submit to my meteor app

What is the easiest thing here? What should I look out for?

Basically my app requires a hosted form and a embeddable form. The hosted form is just a page in the meteor app, the embeddable form goes into a wordpress site (or anywhere really I guess).

I suppose the easiest is just a iframe? But then the styling won’t match the environment it’s embedded in. Is the only other option giving them a form submission endpoint and api key (via PIcker or restivus)? I REALLY want to avoid putting together a api key system.

I guess like hubspots:

similar question to this maybe:

FURTHER READING:

https://codeutopia.net/blog/2012/05/26/best-practices-for-building-embeddable-widgets/

1 Like

Yeah I think those are pretty much your options - API or iframe - what else could you do?

I think it should be possible to let an frame be styled through a bit of hacking actually. I think the only things from “the outside” that the iframe has access to is the name attribute and the url. So you could use either the name or a url parameter as a style string, which you then insert into a style tag on load. Or you could allow them to pass the url of a css which you load with ajax.

1 Like

Thanks. I’ll try to compile some reading links here for others.