1
我有一個非常老的rails應用程序試圖向新用戶發送驗證郵件,但永遠不會找到該標記,因爲由於某種原因鏈接無論如何獲得3D預先添加到字符串我生成鏈接。由於某種原因,它似乎也正在向標記的中間注入=號。Rails 2郵件程序視圖預先填充3D到字符串
下面是一些代碼輸出:
<%= link_to verify_account_url(:host => (ActionMailer::Base.default_url_options[:host] || ''), :t => @token), verify_account_url(:host => (ActionMailer::Base.default_url_options[:host] || ''), :t => @token) %>
<a href=3D"https://localhost:3000/accounts/verify?t=3Dd486da2ac8a6dea8a3d9ce341c7aa6=
b01cca96ea">https://localhost:3000/accounts/verify?t=3Dd486da2ac8a6dea8a3d9ce341c7aa6b0=
1cca96ea</a>
,並在數據庫中的令牌是:
#<AccountToken id: 6317, token: "d486da2ac8a6dea8a3d9ce341c7aa6b01cca96ea", email: "...", client: nil>
我也嘗試了硬編碼的URL和插在字符串輸出的標記,但同樣的問題正在發生,它似乎也發生在正常的HTML標籤中,例如:
<p style="margin: 0 0 1em;">If clicking the link doesn't work, copy and paste the link into your browser's address bar.</p>
結果於
<p style=3D"margin: 0 0 1em;">If clicking the link doesn't work, copy a=nd paste the link into your browser's address bar.</p>
任何人有什麼想法?
啊我想這是從我的開發日誌閱讀我的郵件的問題。謝謝 – Jimmy 2014-09-05 16:01:13