标签: javascript jquery gmail-api
我有一个包含静态联系人页面的静态网站。我希望只使用javascript来允许用户使用本网站与我们联系。我已经看到有一个Gmail oauth可以做到这一点,但没有找到任何示例代码。有人能告诉我是否可以在javascript中执行此操作?
我试过这个:Sending EMail from my Javascript App via GMail API - mail appears in GMail sent list, but isn't delivered to destination email address
并在控制台中获得以下异常:
X-Frame-Options拒绝加载: https://accounts.google.com/o/oauth2/auth?client_id=33434344.apps.googleusercontent.com&scope=https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fgmail.readonly%20https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fgmail.send&immediate=true&include_granted_scopes=true&proxy=oauth2relay893566989&redirect_uri=postmessage&origin=http%3A%2F%2F127.0.0.1%3A8000&response_type=token&gsiwebsdk=1&state=505139957%7C0.3440281612&authuser=0&jsh=m%3B%2F_%2Fscs%2Fapps-static%2F_%2Fjs%2Fk%3Doz.gapi.en_GB.R4vvmD-bxFg.O%2Fm%3D__features__%2Fam%3DAQ%2Frt%3Dj%2Fd%3D1%2Frs%3DAGLTcCNqw3woMCdGPJ1k0Sr5vKTnVpzXbw不允许跨源框架。