y7kim / agency-jekyll-theme

Agency Theme for Jekyll
Apache License 2.0
869 stars 2.02k forks source link

Email Form #14

Closed allochory closed 7 years ago

allochory commented 9 years ago

Hello!

I'm using your theme and it is great. However, I've run into one final poblem with the email form. I get the error "Sorry , it seems that my mail server is not responding. Please try again later!" I am not sure where the problem is coming from... I've tried changing the email in the _config.yml and contact_me.php, to no avail. I'm new to this, so perhaps there is something wrong with my setup. Any thoughts?

y7kim commented 9 years ago

Hi,

First of all, thanks for using the theme!

Your issue is actually expected, as github pages only serves static content

First, you will need to sign up for a mail sending service like SendGrid or Mandrill, which allows you to send email via a Javascript API.

Then, you can modify the ajax request in the 'submitSuccess' method (line20) in /js/contact_me.js - you will have to replace the url field with the appropriate API endpoint, and pass the appropriate parameters according to your mail service provider.

Those are the high-level instructions I will leave you with - if you have any more questions about implementing it, just let me know. I may be able to give you some more hands-on help if you are not that familiar with JS and API's.

Best,

Rick

On Sat, May 30, 2015 at 5:40 AM, allochory notifications@github.com wrote:

Hello!

I'm using your theme and it is great. However, I've run into one final poblem with the email form. I get the error "Sorry , it seems that my mail server is not responding. Please try again later!" I am not sure where the problem is coming from... I've tried changing the email in the _config.yml and contact_me.php, to no avail. I'm new to this, so perhaps there is something wrong with my setup. Any thoughts?

— Reply to this email directly or view it on GitHub https://github.com/y7kim/agency-jekyll-theme/issues/14.

allochory commented 9 years ago

Rick,

Thanks! This is great. I am not familiar, as this is only my second website, but I'll dive in and see how things go. I appreciate your help and if I get completely stuck I might take you up on your offer!

Tyler

2015-05-30 18:27 GMT+02:00 Rick K. notifications@github.com:

Hi,

First of all, thanks for using the theme!

Your issue is actually expected, as github pages only serves static content

  • ie. mail/contact_me.php doesn't work when hosted on github pages. It is not too hard to fix however:

First, you will need to sign up for a mail sending service like SendGrid or Mandrill, which allows you to send email via a Javascript API.

Then, you can modify the ajax request in the 'submitSuccess' method (line20) in /js/contact_me.js - you will have to replace the url field with the appropriate API endpoint, and pass the appropriate parameters according to your mail service provider.

Those are the high-level instructions I will leave you with - if you have any more questions about implementing it, just let me know. I may be able to give you some more hands-on help if you are not that familiar with JS and API's.

Best,

Rick

On Sat, May 30, 2015 at 5:40 AM, allochory notifications@github.com wrote:

Hello!

I'm using your theme and it is great. However, I've run into one final poblem with the email form. I get the error "Sorry , it seems that my mail server is not responding. Please try again later!" I am not sure where the problem is coming from... I've tried changing the email in the _config.yml and contact_me.php, to no avail. I'm new to this, so perhaps there is something wrong with my setup. Any thoughts?

— Reply to this email directly or view it on GitHub https://github.com/y7kim/agency-jekyll-theme/issues/14.

— Reply to this email directly or view it on GitHub https://github.com/y7kim/agency-jekyll-theme/issues/14#issuecomment-107059592 .

zbeekman commented 8 years ago

@allochory: Take a look at my version for an email form that works on github pages: https://github.com/zbeekman/zbeekman.github.io

y7kim commented 8 years ago

very nice solution zbeekman, thanks.

Tamxaun commented 8 years ago

Hello, I have a similar problem, my form doesn't validate information, just sends the message (

Tamxaun commented 8 years ago

okay I get it now, it seems that input wrap required a proper class

zbeekman commented 8 years ago

@Tamxaun can you please elaborate on the fix?

Tamxaun commented 8 years ago

it works when the wrap of input have a class .control-group, here is the example:

<fieldset class="control-group">
    <input id="email" type="email" data-validation-required-message="Please enter your email" required>
    <p class="help-block text-danger"></p>
</fieldset>
shoichiaizawa commented 8 years ago

The email form issue still seems persistent even after this fix #33. I was wondering what else I was missing to make it work :cry:

KompiAjaib commented 8 years ago

Thanks Mr. @zbeekman It was awesome... works perfectly on my blog

thinkjrs commented 6 years ago

Also wanted to add my thanks to @zbeekman for the static email solution. I updated the URL on line 23 in /assets/js/contact_me.js (as suggested by @y7kim ) to //formspree.io/"myemail@blah.com" and after confirmation, it just works.

Thanks for sharing your hard work!

leicao-me commented 6 years ago

@thinkjrs Thank you very much. You gave a concrete solution of @y7kim 's answer.

nedojp commented 5 years ago

@thinkjrs is it possible to get a little bit of support in the contact form?

Belmires commented 3 years ago

Boa Tarde, estou como o mesmo problema alguém poderia me ajudar ?

AsadbekNematov commented 3 years ago

Rick,

Thanks! This is great. I am not familiar, as this is only my second website, but I'll dive in and see how things go. I appreciate your help and if I get completely stuck I might take you up on your offer!

Tyler

2015-05-30 18:27 GMT+02:00 Rick K. notifications@github.com:

Hi, First of all, thanks for using the theme! Your issue is actually expected, as github pages only serves static content

  • ie. mail/contact_me.php doesn't work when hosted on github pages. It is not too hard to fix however:

First, you will need to sign up for a mail sending service like SendGrid or Mandrill, which allows you to send email via a Javascript API. Then, you can modify the ajax request in the 'submitSuccess' method (line20) in /js/contact_me.js - you will have to replace the url field with the appropriate API endpoint, and pass the appropriate parameters according to your mail service provider. Those are the high-level instructions I will leave you with - if you have any more questions about implementing it, just let me know. I may be able to give you some more hands-on help if you are not that familiar with JS and API's. Best, Rick On Sat, May 30, 2015 at 5:40 AM, allochory notifications@github.com wrote:

Hello! I'm using your theme and it is great. However, I've run into one final poblem with the email form. I get the error "Sorry , it seems that my mail server is not responding. Please try again later!" I am not sure where the problem is coming from... I've tried changing the email in the _config.yml and contact_me.php, to no avail. I'm new to this, so perhaps there is something wrong with my setup. Any thoughts? — Reply to this email directly or view it on GitHub

14.

— Reply to this email directly or view it on GitHub #14 (comment) .

good morning. i am not familiar to APS so can i ask where i can get API to replace