| 开发者 | coffee2code |
|---|---|
| 更新时间 | 2018年4月18日 13:02 |
| 捐献地址: | 去捐款 |
| PHP版本: | 4.7 及以上 |
| WordPress版本: | 4.9 |
| 版权: | GPLv2 or later |
| 版权网址: | 版权信息 |
admin-post-navigation.zip inside the /wp-content/plugins/ directory for your site (or install via the built-in WordPress plugin installer)See the Filters section for the c2c_admin_post_navigation_orderby filter, which has just such an example.
Yes. See the Filters section for the c2c_admin_post_navigation_prev_text and/or c2c_admin_post_navigation_next_text filters, which have just such examples. To change or amend the overall markup for the links, look into the c2c_admin_post_navigation_display filter.
$user_id arg to get_post_type_orderby(), and use it, to take into account user preference.$user_id arg to 'c2c_admin_post_navigation_orderby' filter.get_setting_name() helper function for getting the setting name for the given post type.screen_settings() to output the dropdown.save_screen_settings() to save user's preference.is_valid_orderby() helper function to verify a given orderby value is valid.get_post_statuses() for getting post statuses valid for navigation of a given post type.get_post_type_orderby().is_post_type_navigable().get_the_title() instead of the_title_attribute() to get post titles.$user_id arg to 'c2c_admin_post_navigation_post_statuses' filter.sprintf() to format output markup rather than concatenating strings, variables, and function calls.WP_TESTS_DIR to /tmp/wordpress-tests-lib rather than erroring out if not defined via environment variable.the_title_attribute() to get post title for use in attribute.add_css() and add_js().