Best way to create a contact form within an electron app?


#1

Good evening everyone,
I am playing around with an Electron application in conjunction with Framework7 for the UI.
Now i had the idea to offer a contact form where people could send an e-mail.

My question is: what would be a good way to solve this?

At this moment i am thinking of creating a simple iframe to www.myserver.com/contact-form.php
But something tells me that this is the wrong way.

Are there any packages or plugins that could work as server for such a simple form?

Thanks in advance for your time and support!


#2

Hello there.

Instead of an iFrame, I’ll recommend a webview element. And as for you form, better use vanilla HTML with Ajax. I don’t know how well PHP renders in an standalone electron app (this of course if it does at all).
Cheers.


#3

Thanks Eddy. The framework (either Framework7 or Vanilla) ain’t the real problem. The hurdle is to have a script passing the form data. To use PHP i would have to use some kind of XAMMP integration so that Electro or the Framework would understand PHP. But that would make the app way too big.
But thanks for your suggestion and support. Greetings from this corner of the planet.