內容簡介
dyn-mailto WordPress 外掛可讓您建立電子郵件鏈接,在訪問頁面的人、頁面訪問源、他們在網站上的位置等因素不同時有不同的加載方式。您可以通過編寫模板來創建電子郵件鏈接,當有人訪問您的網站時,模板將被替換為適當的字段。
此外掛允許您編寫動態電子郵件鏈接,可以訪問以下信息:
* WordPress 用戶帳戶(如果已登錄)
* WordPress 網站本身
* 在該鏈接上查看的 WordPress 貼文
* 用戶的 IP 地址和地理位置,包括國家、地區和城市
除了在鏈接中包含相關數據外,動態電子郵件鏈接還可以包含有用的邏輯結構,包括 if 陳述句、循環和隨機化字段。
此外掛使用 FreeGeoIP API 檢索訪問者位置以供電子郵件模板使用。只有在郵件模板中使用位置字段時,才會調用此 API,並且僅在呈現該特定模板時才會調用 API。未使用任何其他第三方 API。
貢獻
此外掛是開放原始碼的。想要做出貢獻嗎?請訪問此外掛的GitHub 存儲庫。
外掛標籤
開發者團隊
原文外掛簡介
The dyn-mailto WordPress plugin enables you to create mailto links that load differently depending on who visits the page, where they visit the page from, where on the site they see the link, and more. You create a mailto link by writing a template that, when it comes time to render to someone visiting your website, has the appropriate fields substituted where ever you’ve designated.
This plugin allows you to write dynamic mailto links that can access information about:
* The WordPress user account (if logged in)
* The WordPress site itself
* The WordPress post that the link is viewed on
* The user’s IP address and geographic location, including country, region and city
In addition to including relevant data in the link, dynamic mailto links can incorporate useful logical constructs, including if statements, loops and randomizing fields.
This plugin makes use of the FreeGeoIP API to retrieve visitor location for use by your mailto templates. This API will not be called unless you make use of location fields inside a mailto template, and the API will only be called when that specific template is rendered. No other 3rd party APIs are used.
Contributing
This plugin is open-source. Want to make a contribution? Visit the plugin GitHub repo.
