PluginProbe
Jetpack – WP Security, Backup, Speed, & Growth / 8.2.6
Jetpack – WP Security, Backup, Speed, & Growth v8.2.6
12.0.3 12.1.3 12.2.3 12.3.2 12.4.2 12.5.2 12.6.4 12.7.3 12.8.3 12.9.5 13.0.2 13.1.5 13.2.4 13.3.3 13.4.5 13.5.2 13.6.2 13.7.2 13.8.3 13.9.2 14.0.1 14.1.1 14.2.2 14.3.1 14.4.2 All 500 releases
jetpack / modules / custom-content-types.php
custom-content-types.php
48 lines 1.3 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 /**
4 * Module Name: Custom content types
5 * Module Description: Display different types of content on your site with custom content types.
6 * First Introduced: 3.1
7 * Requires Connection: No
8 * Auto Activate: No
9 * Module Tags: Writing
10 * Sort Order: 34
11 * Feature: Writing
12 * Additional Search Queries: cpt, custom post types, portfolio, portfolios, testimonial, testimonials
13 */
14
15 function jetpack_load_custom_post_types() {
16 include dirname( __FILE__ ) . "/custom-post-types/portfolios.php";
17 }
18
19 function jetpack_custom_post_types_loaded() {
20 Jetpack::enable_module_configurable( __FILE__ );
21 }
22 add_action( 'jetpack_modules_loaded', 'jetpack_custom_post_types_loaded' );
23
24 // Add Settings Section for CPT
25 function jetpack_cpt_settings_api_init() {
26 add_settings_section(
27 'jetpack_cpt_section',
28 '<span id="cpt-options">' . __( 'Your Custom Content Types', 'jetpack' ) . '</span>',
29 'jetpack_cpt_section_callback',
30 'writing'
31 );
32 }
33 add_action( 'admin_init', 'jetpack_cpt_settings_api_init' );
34
35 /*
36 * Settings Description
37 */
38 function jetpack_cpt_section_callback() {
39 ?>
40 <p>
41 <?php esc_html_e( 'Use these settings to display different types of content on your site.', 'jetpack' ); ?>
42 <a target="_blank" href="https://jetpack.com/support/custom-content-types/"><?php esc_html_e( 'Learn More', 'jetpack' ); ?></a>
43 </p>
44 <?php
45 }
46
47 jetpack_load_custom_post_types();
48