restore_previous_locale

动作钩子
do_action( 'restore_previous_locale', $locale, $previous_locale )
参数
  • (string) $locale The new locale.
    Required:
  • (string) $previous_locale The previous locale.
    Required:
定义位置
相关勾子
wp_restore_post_revisiondetermine_localeredirect_post_locationcore_version_check_localerest_prepare_block_type
相关方法
restore_previous_localerestore_current_localeget_previous_postwp_restore_post_revisionrest_api_loadedget_user_locale
引入
4.7.0
弃用
-

restore_previous_locale: 这是一个WordPress的函数,可以恢复以前的语言设置。它被用来在执行了一个需要不同地域的操作后切换回原来的地域。

当语言环境被恢复到以前的语言环境时触发。

do_action( 'restore_previous_locale', $locale, $previous_locale );

常见问题

FAQs
查看更多 >
闪电侠

(工作日 10:00 - 18:30 为您服务)

2025-12-06 14:33:20

您好,无论是售前、售后、意见建议……均可通过联系工单与我们取得联系。

您也可选择聊天工具与我们即时沟通或点击查看:

您的工单我们已经收到,我们将会尽快跟您联系!
取消
选择聊天工具: