learn-to-send-email-via-google-script-html-no-server icon indicating copy to clipboard operation
learn-to-send-email-via-google-script-html-no-server copied to clipboard

Redirecting?

Open eetuhal opened this issue 3 years ago • 4 comments

After submitting the form I got {"result":"success","data":"{"msg":[""],"name":[""],"email":[""]}"}. How do I redirect to the original page with url?

eetuhal avatar Jan 10 '22 16:01 eetuhal

Hi,

It is not working...

What return statement you mean specifically?

Thank a lot

su 23. tammik. 2022 klo 11.04 Aditya Ajmera @.***) kirjoitti:

For redirecting, I used: return HtmlService.createHtmlOutput( "" );

in place of the earlier return statement.

(From StackOverflow)

— Reply to this email directly, view it on GitHub https://github.com/dwyl/learn-to-send-email-via-google-script-html-no-server/issues/421#issuecomment-1019442258, or unsubscribe https://github.com/notifications/unsubscribe-auth/AKGQZEWKAEJELW5YQGM7Q6DUXPABHANCNFSM5LUCPN7A . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you authored the thread.Message ID: <dwyl/learn-to-send-email-via-google-script-html-no-server/issues/421/1019442258 @github.com>

eetuhal avatar Jan 24 '22 16:01 eetuhal

https://github.com/dwyl/learn-to-send-email-via-google-script-html-no-server#part-two---make-it-look-good-

bledatunay avatar Jan 25 '22 14:01 bledatunay

After following those steps I cant seem to make it no redirect

AidanTheBandit avatar Apr 27 '22 03:04 AidanTheBandit

Download the repo, open up test.html and submit a form. If that works, you are indeed missing something in your project. If that is not working as well, it should be related to your browser / extensions (some ad-blocker filters are known to block ajax calls).

Note that, what README.md explains and what ajax does has nothing to do with redirecting per se - json is not somehow redirected to the main page, instead, we are not leaving the page in the first place by using ajax. So you might want to reconsider what you're trying to accomplish.

bledatunay avatar May 01 '22 04:05 bledatunay