PluginProbe ʕ •ᴥ•ʔ
Pods – Custom Content Types and Fields / 3.3.7
Pods – Custom Content Types and Fields v3.3.7
trunk 1.14.8 2.7.31.3 2.8.23.3 2.9.19.3 3.0.10.3 3.1.4.1 3.2.0 3.2.1 3.2.1.1 3.2.2 3.2.4 3.2.5 3.2.6 3.2.7 3.2.7.1 3.2.8 3.2.8.1 3.2.8.2 3.3.0 3.3.1 3.3.2 3.3.3 3.3.4 3.3.5 3.3.6 3.3.7 3.3.8 3.3.9
pods / components / Table-Storage.php
pods / components Last commit date
I18n 4 months ago Migrate-ACF 4 months ago Migrate-CPTUI 4 months ago Migrate-PHP 4 months ago Migrate-Packages 4 months ago Roles 4 months ago Templates 4 months ago Advanced-Content-Types.php 4 months ago Advanced-Relationships.php 4 months ago Markdown.php 4 months ago Pages.php 4 months ago Table-Storage.php 4 months ago
Table-Storage.php
54 lines
1 <?php
2
3 // Don't load directly.
4 if ( ! defined( 'ABSPATH' ) ) {
5 die( '-1' );
6 }
7
8 /**
9 * Name: Table Storage
10 *
11 * Description: Enable a custom database table for your custom fields on Post Types, Media, Taxonomies, Users, and Comments.
12 *
13 * Version: 2.3
14 *
15 * Category: Advanced
16 *
17 * Tableless Mode: No
18 *
19 * @package Pods\Components
20 * @subpackage Advanced Content Types
21 */
22
23 if ( class_exists( 'Pods_Table_Storage' ) ) {
24 return;
25 }
26
27 /**
28 * Class Pods_Table_Storage
29 */
30 class Pods_Table_Storage extends PodsComponent {
31
32 /**
33 * {@inheritdoc}
34 */
35 public function init() {
36 // Bypass if Pods is in types-only mode.
37 if ( pods_is_types_only() ) {
38 return;
39 }
40
41 // Bypass if Pods is in tableless mode.
42 if ( pods_tableless() ) {
43 return;
44 }
45
46 add_filter( 'pods_admin_setup_add_create_storage', '__return_true' );
47 add_filter( 'pods_admin_setup_add_create_taxonomy_storage', '__return_true' );
48
49 add_filter( 'pods_admin_setup_add_extend_storage', '__return_true' );
50 add_filter( 'pods_admin_setup_add_extend_taxonomy_storage', '__return_true' );
51 }
52
53 }
54