外掛說明
這個易用的外掛可以讓網站管理員不需編輯程式碼,便能變更外掛、佈景主題及 WordPress 核心程式的譯文字串。僅需輸入目前的字串以及想要變更的字串結果,這個外掛便會自動完成其他工作。
請在這個外掛的 GitHub 存放庫中進行分支或參與專案。
Say What Pro 還提供以下功能:
- 字串探索及自動完成:不需深入研究程式碼即可查詢需要變更的字串。這項功能適用於伺服器端及 JavaScript 轉譯的字串。
- 使用
text-domain-specific
篩選器改進執行效能。 - 萬用字元字串取代:取代全站中的個別詞彙或或片段內容。
- 多語言支援– 在多語言網站上為不同語言設定不同的替換語言
- 匯入/匯出功能:透過使用者介面輕鬆匯入/匯出取代字串。
支持這個免費外掛
作為一名企業家,我們會將付費版外掛的部分利潤用於贊助全球氣候變遷專案。使用者可以免費使用這個外掛,但如果願意,可以考慮為這個世界購買樹木做為回饋,這也能為當地家庭創造就業機會,並恢復野生動物的棲地。
安裝方式
- 使用與其他外掛相同方式完成安裝。
- 啟用外掛。
- 前往 [工具]→[文字變更],然後設定字串替換。
常見問題集
-
這個外掛是否可變更任何字串?
-
網站管理員使用這個外掛,僅能適用於符合 WordPress 國際化程式碼標準的字串。
-
如何找到可本地化的字串?
-
使用者可以自行猜測,或是查看相關外掛的原始程式碼,可本地化的字串通常會以
__()
、_e()
、_n()
或_x()
等函式撰寫。範例如下:$foo = __('This is a translatable string', 'plugin-domain');
這篇文章展示了更多可供參考的範例。此外,這個外掛的 Pro 版提供 [字串搜尋] 模式,這代表使用者可以透過自動建議搜尋網站上的字串。
-
是否支援匯入取代字串?
-
Say What? 外掛已初步支援使用 WP-CLI 匯出及匯入取代字串,以下是目前支援的命令:
- export:匯出目前全部取代字串。
- import:從 CSV 檔案匯入取代字串。
- list:匯出目前全部取代字串,與 export 命令相同。
- update:從 CSV 檔案更新取代字串。
請查看這個外掛的 GitHub 存放庫以了解命令使用方式。
-
是否可為不同語言設定不同的取代字串?
-
免費版外掛沒有這項功能,這項功能僅於這個外掛的 Pro 版提供。
使用者評論
參與者及開發者
變更記錄
2.2.5
- General tidy-ups and maintenance
2.2.4
- Fix: Do not generate warning on initial install
2.2.3
- Change: Internal package updates
- Change: Compatibility with WordPress 6.6
2.2.2
- Fix: Resolve issue where replacements weren’t made if an external object cache was in use.
2.2.1
- Change: Internal refactor of classes
2.1.9
- Change: Minor admin UI changes
2.1.8
- Fix: Include missing image
2.1.7
- Change: Admin UI updates
2.1.6
- Change: Styling & documentation updates.
2.1.5
- Fix: Avoid warning when sorting list table.
2.1.4
- Change: Localisation improvements
2.1.3
- Change: Updates to Javascript dependencies.
2.1.2
- Change: Updates to Javascript dependencies, smaller JS footprint.
2.1.1
- Fix: Resolve issue where console errors could be thrown if no replacements configured.
2.1.0
- New: Optimise performance when an external object cache is available
- Fix: Imports via WP-CLI could fail if the pro extension had previously been active
2.0.2
- Reduce size of bundled images
- Update dev build scripts
2.0.1
- Improve Javascript performance, and remove lodash dependency (resolves some plugin conflicts)
2.0.0
- Support for translatable strings rendered through WordPress Javascript framework
- Supports replacing text in Gutenberg / WooCommerce admin / WooCommerce blocks
- Update details of Say What? Pro vs free plugin
1.9.7
- Fix issue where replacement table disappeared at small screen widths
- Update WordPress compatibility
- Changes to donation / upsell content
1.9.6
- Fix link in documentation
1.9.5
- WordPress 5.5 compatibility
- Changes to Treeware links
1.9.4
- Ensure help links open in new windows
1.9.3
- Fix link target in Treeware content
1.9.2
- Suggest Treeware donations
1.9.1
- Update information about Pro features
1.9.0
- Fix issue adding more strings after downgrade from Pro
- Update text domain of plugin to match wordpress.org guidelines to aid translations
1.8.2
- Documentation updates only
1.8.1
- Update plugin links, include settings and upgrade link
- Update documentation about pro features
- Admin styling fixes
1.8.0
- Fix issues where entities could be double encoded on admin screens.
1.7.1
- Update to admin marketing message. No functional changes.
1.7
- Support for _n() and _nx()
- Support for multi-line strings
1.6
Introduce filters that allows back compatibility for plugins that change their text-domain. Props Pippin Williamson
1.5
Avoid warnings on initial activation.
Avoid issues where strings contain HTML / entities
1.4
Add info box about Pro version
1.3
Support for WP-CLI import and export.
1.2
Swap database to UTF-8 to fix problems entering non-ASCII strings.
1.1
Fix incorrect escaping on the admin screens.
1.0.1
Fix initial DB table creation
Fix translations for strings with no domain
1.0
Allow strings with context to be replaced
0.9.3
Documentation improvements
0.9.2
Avoid wpdb->prepare warning
Minor admin fixes, don’t double translate strings
0.9.1
Fix issue with fields being swapped when first entered
0.9
Beta ready for testing and feedback