前言介紹
- 這款 WordPress 外掛「Customizer Responsive Server-Side Components Device Preview」是 2016-10-28 上架。
- 目前有 70 個安裝啟用數。
- 上一次更新是 2017-11-09,距離現在已有 2733 天。超過一年沒更新,安裝要確認版本是否可用。以及後續維護問題!
- 外掛最低要求 WordPress 4.7 以上版本才可以安裝。
- 外掛要求網站主機運作至少需要 PHP 版本 5.3 以上。
- 尚未有人給過這款外掛評分。
- 還沒有人在論壇上發問,可能目前使用數不多,還沒有什麼大問題。
外掛協作開發者
xwp | westonruter |
外掛標籤
rwd | adaptive | customize | customizer | responsive |
內容簡介
閱讀完整介紹: 在 Customizer 中預覽自適應設計主題。
此外掛擴充了在 4.5 版本新增的 Customizer 響應式裝置預覽功能(請見 #31195)。在核心功能中,當您變更所預覽的裝置時,僅會更改預覽的尺寸,允許您模擬主題在平板電腦或行動裝置屏幕上的外觀,但它並未觸發預覽重新載入,並以當前預覽的裝置偽裝 User-Agent。對於實現響應式設計的主題,這種核心行為很好用,因為改變 iframe 的尺寸將導致適當的媒體查詢適用。然而,如果您的主題採用了自適應設計,那麼您將無法看到它在不同設備上顯示的任何服務端組件。例如,在行動裝置上,主題可能會希望完全跳過輸出側邊欄以節省頻寬。
此外掛將確保當更改預覽裝置時,預覽被重新加載並更改預覽窗口大小。它會在正在預覽的 URL 中傳遞一個 customize_previewed_device 查詢參數,此參數將是 desktop、tablet 或 mobile 中的一個。此外掛將覆蓋 $_SERVER['HTTP_USER_AGENT'] 以成為所提供裝置類型的用戶代理,因此對 wp_is_mobile()、jetpack_is_mobile() 和 Jetpack_User_Agent_Info::is_tablet() 的呼叫都會根據當前預覽的裝置類型返回預期值。
此外掛的開發在 GitHub 上進行。歡迎提交拉取請求。請先查看報告的 問題,再前往 此外掛論壇。
原文外掛簡介
Read full writeup: Previewing Themes with Adaptive Designs in the Customizer.
This plugin extends the responsive device preview functionality in the customizer which was added in 4.5 (see #31195). In core when you change the previewed device it merely changes the dimensions of the preview, allowing you to simulate how the theme will appear on tablet or mobile screens. What it does not do, however, is cause the preview to reload with the User-Agent overridden for the current device being previewed. For themes that implement a responsive design this core behavior is just fine since changing the dimensions of the iframe will cause the appropriate media queries to apply. However, if you have an adaptive design for your theme you won’t be able to see any server-side components that it may display when viewing a different device. For example, on mobile devices a theme may want to skip outputting the sidebar altogether to save on bandwidth.
This plugin will ensure that the preview is refreshed when the previewed device is changed in addition to changing the preview window size. It will pass a customize_previewed_device query parameter on the URL being previewed, and this parameter will be either desktop, tablet, or mobile. The plugin will override the $_SERVER['HTTP_USER_AGENT'] to be a user agent representative of the supplied device type so that calls to wp_is_mobile(), jetpack_is_mobile(), and Jetpack_User_Agent_Info::is_tablet() will all return the expected values based on the current previewed device.
Development of this plugin is done on GitHub. Pull requests welcome. Please see issues reported there before going to the plugin forum.
各版本下載點
- 方法一:點下方版本號的連結下載 ZIP 檔案後,登入網站後台左側選單「外掛」的「安裝外掛」,然後選擇上方的「上傳外掛」,把下載回去的 ZIP 外掛打包檔案上傳上去安裝與啟用。
- 方法二:透過「安裝外掛」的畫面右方搜尋功能,搜尋外掛名稱「Customizer Responsive Server-Side Components Device Preview」來進行安裝。
(建議使用方法二,確保安裝的版本符合當前運作的 WordPress 環境。
延伸相關外掛(你可能也想知道)
Camera slideshow 》如果你正在尋找一個先進的 WordPress 幻燈片: Shortcodelic plugin bundle (它還包括許多其他功能:選項卡,手風琴,Google 地圖,價格表,頁面組合器……)...。
Hammy 》介紹, Hammy 可以對正常的內容圖片(僅限於文章和頁面,而不是自定義文章類型)進行重新調整大小,生成多個不同尺寸的圖片。當使用者訪問網站時,自動提供最...。
Adaptive Learning With LearnDash 》此外掛允許課程管理員以非線性的方式設計課程,可以有多個具有不同課程級別的子課程,學生將根據其在先決/確定性/父課程測驗的表現分配子課程。, 如需更高級...。
Mobile Switcher 》這個外掛可以讓你設置不同的主題在行動裝置上顯示。, 透過這個外掛,你可以為平板電腦、手機或桌面電腦的使用者選擇會顯示的主題。, Readme Generator, 這份 ...。
Nice Backgrounds 》管理大型的自適應(適應行動裝置)圖片,並自動將它們應用到WordPress網站上的區域背景中。, 使用內置瀏覽器從Unsplash中提取美麗的照片,或者從上傳和提供的...。
AddFunc Adaptive Content 》隨著市場上新型的網路裝置越來越多,螢幕大小和數據傳輸速度也各不相同,一個網站無法在每次請求時提供相同的內容(不做限制和/或流量損失是不可能的)。, 這...。
SS Device Detector 》這款外掛的目的是幫助 WordPress 使用者和開發人員分別使用短碼和功能,為他們的主題實現伺服器端的回應式解決方案。, 與像是 display:none 的解決方案相比,...。