ascvh@#%(^-^)V ?host,ip,port,protocol,title,domain,country,city,link,org ???à JFIF x x ?? C ?? C ?à " ?? ?? μ } !1AQa "q2?‘?#B±áR?e$3br? %&'()*456789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz??…???‰?’“”?–—???¢£¤¥|§¨?a23′μ?·?1o??????èéêòó???×?ùúáa?????èéê?òó???÷?ùú?? ?? μ w !1AQ aq"2?B‘?±á #3Rebr?{
File "class-object-meta-db-forms.php"
Full Path: /home/zcziejy/ryadselyen/plugins/wp-booking-system/includes/base/form/class-object-meta-db-forms.php
File size: 1.59 KB
MIME-type: text/x-php
Charset: utf-8
<?php
// Exit if accessed directly
if ( ! defined( 'ABSPATH' ) ) exit;
/**
* Class that handles database queries for the Forms
*
*/
Class WPBS_Object_Meta_DB_Forms extends WPBS_Object_Meta_DB {
/**
* Construct
*
*/
public function __construct() {
global $wpdb;
$this->table_name = $wpdb->prefix . 'wpbs_form_meta';
$this->primary_key = 'form_id';
$this->context = 'form';
add_action( 'plugins_loaded', array( $this, 'register_wpdb_column' ) );
}
/**
* Register the meta table for the forms with the $wpdb global
*
*/
public function register_wpdb_column() {
global $wpdb;
$meta_table_name = $this->context . 'meta';
$wpdb->{$meta_table_name} = $this->table_name;
}
/**
* Return the table columns
*
*/
public function get_columns() {
return array(
'meta_id' => '%d',
'form_id' => '%d',
'meta_key' => '%s',
'meta_value' => '%s'
);
}
/**
* Creates and updates the database table for the forms
*
*/
public function create_table() {
global $wpdb;
$table_name = $this->table_name;
$charset_collate = $wpdb->get_charset_collate();
$query = "CREATE TABLE {$table_name} (
meta_id bigint(20) NOT NULL AUTO_INCREMENT,
form_id bigint(20) NOT NULL DEFAULT '0',
meta_key varchar(255) DEFAULT NULL,
meta_value longtext,
PRIMARY KEY (meta_id),
KEY form_id (form_id),
KEY meta_key (meta_key(191))
) {$charset_collate};";
require_once( ABSPATH . 'wp-admin/includes/upgrade.php' );
dbDelta( $query );
}
}