简体   繁体   English

如何从 WordPress 主题文件或插件重命名管理菜单?

[英]How to Rename the Admin Menu From WordPress theme files or plugin?

在此处输入图像描述

I want to change the blue marked portfolio menu to Course.我想将蓝色标记的投资组合菜单更改为课程。 Basically I want to change--- Portfolios--->> Courses Add New Portfolio -->> Add New Course基本上我想改变--- Portfolios--->> Courses Add New Portfolio -->> Add New Course

And When I add click on add new portfolio it is show add new portfolio.当我添加点击添加新的投资组合时,它会显示添加新的投资组合。 Instead of this I want to show add new course and course setting in the marked area.而不是这个,我想在标记区域显示添加新课程和课程设置。

I just want to edit it from theme file but unable find it out.我只想从主题文件中编辑它但找不到它。 Help..me帮我

which plugin you have used for Adding Portfolios?您使用哪个插件来添加投资组合? you can customize it by editing theme/plugin templates.您可以通过编辑主题/插件模板来自定义它。 you will See admin folder which will contain all these files.您将看到包含所有这些文件的管理文件夹。 these name can also be stored in variables so i cant respond to your qurey without access to FTP.这些名称也可以存储在变量中,因此如果不访问 FTP,我将无法响应您的查询。

Try add_filter( 'post_type_labels_post', 'rename_labels' ) hook尝试add_filter( 'post_type_labels_post', 'rename_labels' )钩子

add_filter( 'post_type_labels_post', 'rename_labels' );
function rename_labels($labels){
  $labels->Portfolio='Course';
  return $labels;   
}

https://wordpress.stackexchange.com/questions/9211/changing-admin-menu-labels https://wordpress.stackexchange.com/questions/9211/changed-admin-menu-labels

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM