Hacker News new | comments | show | ask | jobs | submit login
[dupe] Contact Forms with Pure JavaScript (squaresend.com)
40 points by modfarm 1426 days ago | hide | past | web | 7 comments | favorite



Not to quibble (actual question), but how is this any more "pure javascript" than most ajax-based email forms... it just submits the form to a server, which is pretty normal way of doing something like that, right?


Let's say you have some static landing pages on S3, and you want a contact form. How would you do it?

Normally you'd have a PHP/python/perl/ruby/node/whatever script listening on the server for an HTTP POST (or AJAX request, or RPC, or websocket, or whatever) that would send the mail for you. But this won't work here because S3.

Your first attempt at solving this will probably be to turn to Mandrill/Mailgun/Postmark/whatever, most of which have some easy way to send an email from javascript, but all of which have some secret API key you need to keep secret. Again, this won't work because S3.

The trick is to find someone who'll run a server for you that will accept messages over an HTTP interface and pass them along to a designated email address. And apparently Squaresend will do this, which is honestly pretty nice if you just want a contact form on your S3 hosted website (which is not that strange a need!).


Yes, I hadn't considered that... indeed, that's quite nice alternative to rolling my own.


Presumably, the difference is that Squaresend runs the server so you don't have to.


Healthy discussion about this new service 3 days ago:

http://news.ycombinator.com/item?id=5598852


At this developer portal https://developer.yummly.com/contact, hosted by 3scale, we created the contact form with Wufoo, which is great for fast results: http://www.wufoo.com/gallery/templates/forms/contact-form/

Of course it is a hosted solution just like squaresend, just another alternative to consider.


Oh Not what I thought, Its not pure JS.




Guidelines | FAQ | Support | API | Security | Lists | Bookmarklet | DMCA | Apply to YC | Contact

Search: