PluginProbe ʕ •ᴥ•ʔ
Custom Post Type Permalinks / 2.1.1
Custom Post Type Permalinks v2.1.1
1.2.0 1.3.0 1.3.1 1.4.0 1.5.1 1.5.2 1.5.4 2.0.0 2.0.1 2.0.2 2.1.1 2.1.2 2.1.3 2.2.0 3.0.0 3.0.1 3.1.0 3.1.1 3.1.3 3.1.4 3.1.5 3.2.0 3.2.1 3.2.2 3.3.0 3.3.1 3.3.4 3.3.5 3.4.0 3.4.0-rc.1 3.4.1 3.4.2 3.4.3 3.4.4 3.4.5 3.5.2 3.5.3 3.5.4 3.5.5 trunk 0.6 0.6.1 0.6.2 0.7 0.7.1 0.7.10 0.7.2 0.7.2.1 0.7.3 0.7.3.1 0.7.4 0.7.4.1 0.7.5 0.7.5.1 0.7.5.2 0.7.5.6 0.7.6 0.7.8 0.7.9 0.7.9.1 0.7.9.2 0.8 0.8.1 0.8.6 0.8.7 0.8.7.1 0.8.7.5 0.8.7.6 0.9 0.9.1 0.9.2.1 0.9.3.1 0.9.3.2 0.9.3.3 0.9.5 0.9.5.1 0.9.5.2 0.9.5.3 0.9.5.4 0.9.5.6 0.9.6 1.0.0 1.0.1 1.0.2 1.0.3 1.0.4 1.0.5 1.1.0
custom-post-type-permalinks / custom-post-type-permalinks.php
custom-post-type-permalinks Last commit date
CPTP 9 years ago assets 9 years ago language 9 years ago .svnignore 9 years ago CONTRIBUTING.md 9 years ago CPTP.php 9 years ago codesniffer.ruleset.xml 9 years ago composer.json 9 years ago custom-post-type-permalinks.php 9 years ago license.txt 12 years ago readme.md 9 years ago readme.txt 9 years ago screenshot-1.png 14 years ago
custom-post-type-permalinks.php
57 lines
1 <?php
2 /*
3 Plugin Name: Custom Post Type Permalinks
4 Plugin URI: https://github.com/torounit/custom-post-type-permalinks
5 Description: Add post archives of custom post type and customizable permalinks.
6 Author: Toro_Unit
7 Author URI: https://torounit.com/
8 Version: 2.1.1
9 Text Domain: custom-post-type-permalinks
10 License: GPL2 or later
11 Domain Path: /language/
12 */
13
14
15 /**
16 *
17 * Custom Post Type Permalinks
18 *
19 * @package Custom_Post_Type_Permalinks
20 * @version 2.1.1
21 */
22
23 define( 'CPTP_PLUGIN_FILE', __FILE__ );
24 $data = get_file_data( __FILE__, array( 'ver' => 'Version', 'lang_dir' => 'Domain Path' ) );
25 define( 'CPTP_VERSION', $data['ver'] );
26 define( 'CPTP_DEFAULT_PERMALINK', '/%postname%/' );
27
28
29 /**
30 *
31 * Autoloader for CPTP.
32 *
33 * @since 1.0.0
34 */
35 function cptp_class_loader( $class_name ) {
36 $dir = dirname( __FILE__ );
37 $file_name = $dir . '/' . str_replace( '_', '/', $class_name ) . '.php';
38 if ( is_readable( $file_name ) ) {
39 include $file_name;
40 }
41 }
42
43 spl_autoload_register( 'cptp_class_loader' );
44
45
46 /**
47 * initialize Plugin
48 */
49 add_action( 'plugins_loaded', array( CPTP::get_instance(), 'init' ) );
50
51
52 /**
53 * Activation hooks.
54 */
55 register_activation_hook( CPTP_PLUGIN_FILE, array( CPTP::get_instance(), 'activate' ) );
56
57