3

我正在尝试在注册我的网站期间为电子邮件验证步骤实现一个操作按钮。这样,用户无需打开邮件即可验证他们的电子邮件地址。

这是电子邮件内容(我使用微数据获取架构信息):

<html>
<header>
    <span itemscope itemtype="http://schema.org/EmailMessage">  
       <meta itemprop="description" content="Email address verification"/>  
       <span itemprop="action" itemscope itemtype="http://schema.org/ConfirmAction">    
          <meta itemprop="name" content="Verify email"/>    
                <span itemprop="handler" itemscope itemtype="http://schema.org/HttpActionHandler">      
                    <link itemprop="url" href="http://www.mywebapp.com:80/start.jsp#verifyEmail:email=user@gdomain.com:code=SOMECODEHERE"/>    
                </span>  
      </span>
   </span>
</header>

<body>

<div>EMAIL CONTENT GOES HERE</div>

</body>
</html>

这是消息的原始输出(减去识别信息):

Delivered-To: usera@mydomain.com
Received: [redacted]
X-Received: [redacted]
Return-Path: <3DEudUQsJB6kPROcPaJWWRNPVJRU.LXVPaJWWRNPROcPaJWWRN.LXV@m3kw2wvrgufz5godrsrytgd7.apphosting.bounces.google.com>
Received: from mail-qa0-x247.google.com (mail-qa0-x247.google.com [2607:f8b0:400d:c00::247])
        by mx.google.com with ESMTPS id [redacted]
        for <usera@mydomain.com>
        (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128);
        Wed, 22 May 2013 15:47:40 -0700 (PDT)
Received-SPF: pass (google.com: domain of 3DEudUQsJB6kPROcPaJWWRNPVJRU.LXVPaJWWRNPROcPaJWWRN.LXV@m3kw2wvrgufz5godrsrytgd7.apphosting.bounces.google.com designates 2607:f8b0:400d:c00::247 as permitted sender) client-ip=[redacted];
Authentication-Results: mx.google.com;
       spf=pass (google.com: domain of 3DEudUQsJB6kPROcPaJWWRNPVJRU.LXVPaJWWRNPROcPaJWWRN.LXV@m3kw2wvrgufz5godrsrytgd7.apphosting.bounces.google.com designates 2607:f8b0:400d:c00::247 as permitted sender) smtp.mail=3DEudUQsJB6kPROcPaJWWRNPVJRU.LXVPaJWWRNPROcPaJWWRN.LXV@m3kw2wvrgufz5godrsrytgd7.apphosting.bounces.google.com;
       dkim=pass header.i=@mydomain.com
Received: by mail-qa0-f71.google.com with SMTP id [redacted]
        for <usera@mydomain.com>; Wed, 22 May 2013 15:47:40 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=mydomain.com; s=google;
        h=mime-version:reply-to:x-google-appengine-app-id
         :x-google-appengine-app-id-alias:message-id:date:subject:from:to
         :content-type;
        bh=7M8srUSN1lKnl3NbWw6ev6fOOT0hfVfJ2enr/ecjDFY=;
        b=m2wv6Vl4HXfSPSIs3WWr0GXxfjZ03FL5rTLl0b1HPVg10iMtMpDg8jLHssB7zfb3je
         U9c2qXT6/9RZlfVJrGfgj5mtawzShfu6keaKTc4XMk1QQ/jjHVzOSyySmlzNKtrrzJMW
         HcQ3Btnj14DyGHIUiViV/QGbFHrJl/E3ep/NI=
MIME-Version: 1.0
X-Received: [redacted];
 Wed, 22 May 2013 15:47:40 -0700 (PDT)
Reply-To: User UserAAA <usera@mydomain.com>
X-Google-Appengine-App-Id: s~myappid
X-Google-Appengine-App-Id-Alias: myappid
Message-ID: [redacted]
Date: Wed, 22 May 2013 22:47:40 +0000
Subject: Email verification
From: User Name <usera@mydomain.com>
To: usera@mydomain.com
Content-Type: multipart/alternative; boundary=20cf3005defc67787a04dd565a35

--20cf3005defc67787a04dd565a35
Content-Type: text/plain; charset=ISO-8859-1; format=flowed; delsp=yes

VERIFY EMAIL ADDRESS

--20cf3005defc67787a04dd565a35
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

<html><header><span itemscope itemtype=3D"http://schema.org/EmailMessage"> =
 <meta itemprop=3D"description" content=3D"Email address verification for M=
yAppAppApp.com"/>  <span itemprop=3D"action" itemscope itemtype=3D"http://s=
chema.org/ConfirmAction">    <meta itemprop=3D"name" content=3D"Verify emai=
l"/>    <span itemprop=3D"handler" itemscope itemtype=3D"http://schema.org/=
HttpActionHandler">      <link itemprop=3D"url" href=3D"http://www.mydomain=
app.com:80/start_file_start.jsp#verifyEmail:email=3Dusera@mydomain.com:code=
=SOMECODESOMECODESOM"/>    </span>  </span></span></header><body><div style=
=3D"font-family:Arial; font-size:12px; color:white; background-color:#96b3d=
3; padding:30px; margin:0 auto; width:500px; box-shadow: 1px 1px 4px #33333=
3, 0 0 20px #555555; margin:auto; margin-top:30px; margin-bottom:30px; bord=
er-style:solid; border-radius: 5px; border-color: #b0c1d3; border-width:2px=
;"><div>VERIFY EMAIL ADDRESS</div></body></html>
--20cf3005defc67787a04dd565a35--

我正在通过我的 GAE 应用程序将这条消息从我自己发送给我自己。在我收到的电子邮件的标题中,我看到它通过了 SPF 和 DKIM 身份验证,但 GMail 没有呈现任何按钮。接收邮件的电子邮件帐户属于 Google Apps 帐户。我已经阅读了几次文档,但我真的不知道我在这里缺少什么。有人有线索吗?谢谢。

4

2 回答 2

3

App Engine 白名单只会在周一左右上线,因此这可能是阻止您的标记被呈现的原因。

您可以尝试按照我们刚刚发布的应用脚本教程来测试 Gmail 中的架构:https ://developers.google.com/gmail/schemas/apps-script-tutorial

于 2013-05-24T00:19:52.593 回答
0

Apps 脚本示例不适用于活动预订。

于 2013-05-24T09:33:34.777 回答