
內容簡介
相對網址 (Relative URL) 外掛可將鏈接(文章、分類、頁面等)應用 wp_make_link_relative 函數來轉換為相對網址。開發人員在手機設備(iPad、iPhone 等)上調試本地 WordPress 實例時非常有用。
注意:此插件僅適用於本地開發。我沒有在生產環境上測試過,可能會出現問題,例如 RSS 資訊中出現不必要的網址或共用網址轉換為相對網址等問題。
更多信息,請訪問我的 網站。
例如:
http://localhost:8080/wp/
會被轉換為:
/wp/
而且..
http://localhost:8080/wp/2012/09/01/hello-world/
會被轉換為:
/wp/2012/09/01/hello-world/
同樣的,
http://localhost:8080/wp/wp-content/themes/twentyeleven/style.css
會被轉換為:
/wp/wp-content/themes/twentyeleven/style.css
啟用此插件後,您可以使用 http://10.0.1.5:8888/wp/ 在 iPad 或其他移動設備上輕鬆訪問本地實例,而無需擔心樣式和導航問題。
外掛標籤
開發者團隊
📦 歷史版本下載
原文外掛簡介
Relative URL applies the wp_make_link_relative function to links (posts, categories, pages, etc.) to convert them to relative URLs. Useful for developers when debugging local WordPress instance on a mobile device (iPad, iPhone, etc.).
Notice: This plugin SHOULD be used for local development only. I haven’t tested on a production environment; it may work with some issues, like unwanted URLs in RSS feed or sharing URLs are replaced with relative URLs, etc.
More information please visit my site.
For example:
http://localhost:8080/wp/
Will be converted to:
/wp/
And..
http://localhost:8080/wp/2012/09/01/hello-world/
Will be converted to:
/wp/2012/09/01/hello-world/
And..
http://localhost:8080/wp/wp-content/themes/twentyeleven/style.css
Will be converted to:
/wp/wp-content/themes/twentyeleven/style.css
Then after activating this plugin, you can simply access your local instance using http://10.0.1.5:8888/wp/ on your iPad or other mobile devices without having styles and navigation issue.
