Plugin Directory

Changeset 1912883


Ignore:
Timestamp:
07/22/2018 12:51:29 AM (8 years ago)
Author:
andru24
Message:

Update to 1.7.7

Location:
tcard-wp/trunk
Files:
14 edited

Legend:

Unmodified
Added
Removed
  • tcard-wp/trunk/admin/TcardTables.php

    r1912560 r1912883  
    11<?php
    2 
    32/**
    43 * @since           1.0.0
     
    2322
    2423        $tcards_version = "1.0";
     24        $tcard_table_db_version = get_option( "tcards_table_db_version" );
    2525
    26         $tcards = $wpdb->prefix . "tcards";
     26        if ( $tcard_table_db_version != $tcards_version ) {
    2727
    28         if($wpdb->get_var('SHOW TABLE LIKE ' . $tcards) != $tcards)
    29         {
    30             $sql = "CREATE TABLE $tcards (
    31                 group_id int(11) NOT NULL AUTO_INCREMENT,
    32                 skin_type varchar(25) NOT NULL,
    33                 skins_number tinyint(1) NOT NULL,
    34                 title varchar(255) NOT NULL,
    35                 publish_up datetime DEFAULT '0000-00-00 00:00:00' NOT NULL,
    36                 modified datetime DEFAULT '0000-00-00 00:00:00' NOT NULL,
    37                 settings text NOT NULL,
    38                 PRIMARY KEY (group_id)
    39             )$charset_collate;";
     28            $tcards = $wpdb->prefix . "tcards";
    4029
    41             require_once(ABSPATH . 'wp-admin/includes/upgrade.php');
    42             dbDelta($sql);
     30            if ( $wpdb->get_var( "SHOW TABLES LIKE '{$tcards}'" ) != $tcards ) {
     31                $sql = "CREATE TABLE $tcards (
     32                    group_id int(11) NOT NULL AUTO_INCREMENT,
     33                    skin_type varchar(25) NOT NULL,
     34                    skins_number tinyint(1) NOT NULL,
     35                    title varchar(255) NOT NULL,
     36                    publish_up datetime DEFAULT '0000-00-00 00:00:00' NOT NULL,
     37                    modified datetime DEFAULT '0000-00-00 00:00:00' NOT NULL,
     38                    settings text NOT NULL,
     39                    PRIMARY KEY (group_id)
     40                ) $charset_collate;";
    4341
    44             add_option('tcards_table_db_version',$tcards_version);
     42                require_once(ABSPATH . 'wp-admin/includes/upgrade.php');
     43                dbDelta($sql);
     44            }
     45            update_option('tcards_table_db_version',$tcards_version);
    4546        }
    4647
    4748        $tcard_skins_version = "1.0";
     49        $tcard_skin_db_version = get_option( "tcard_skin_db_version" );
    4850
    49         $tcard_skins = $wpdb->prefix . "tcard_skins";
     51        if ( $tcard_skin_db_version != $tcard_skins_version ) {
    5052
    51         if($wpdb->get_var('SHOW TABLE LIKE ' . $tcard_skins) != $tcard_skins)
    52         {
    53             $sql = "CREATE TABLE $tcard_skins (
    54                 skin_id int(11) NOT NULL AUTO_INCREMENT,
    55                 group_id int(11) NOT NULL,
    56                 closed tinyint(1) NOT NULL,
    57                 elements text NOT NULL,
    58                 header text NOT NULL,
    59                 content mediumtext NOT NULL,
    60                 footer text NOT NULL,
    61                 gallery text NOT NULL,
    62                 settings text NOT NULL, 
    63                 PRIMARY KEY (skin_id)
    64             )$charset_collate;";
     53            $tcard_skins = $wpdb->prefix . "tcard_skins";
     54            if ( $wpdb->get_var( "SHOW TABLES LIKE '{$tcard_skins}'" ) != $tcard_skins ) {
     55                $sql_skin = "CREATE TABLE $tcard_skins (
     56                    skin_id int(11) NOT NULL AUTO_INCREMENT,
     57                    group_id int(11) NOT NULL,
     58                    closed tinyint(1) NOT NULL,
     59                    elements text NOT NULL,
     60                    header text NOT NULL,
     61                    content mediumtext NOT NULL,
     62                    footer text NOT NULL,
     63                    gallery text NOT NULL,
     64                    settings text NOT NULL, 
     65                    PRIMARY KEY (skin_id)
     66                ) $charset_collate;";
    6567
    66             require_once(ABSPATH . 'wp-admin/includes/upgrade.php');
    67             dbDelta($sql);
    68 
    69             add_option('tcard_skin_db_version',$tcard_header_version);
     68                require_once(ABSPATH . 'wp-admin/includes/upgrade.php');
     69                dbDelta($sql_skin);
     70            }
     71            update_option('tcard_skin_db_version',$tcard_skins_version);
    7072        }
    71 
    7273    }
    7374}
  • tcard-wp/trunk/admin/css/tcard-admin.css

    r1912812 r1912883  
    33 Author: Cloanta Alexandru
    44 Name: Tcard Wordpress
    5  Version: 1.7.6
     5 Version: 1.7.7
    66 
    77 */
  • tcard-wp/trunk/admin/css/tcard-admin.min.css

    r1912812 r1912883  
    33 Author: Cloanta Alexandru
    44 Name: Tcard Wordpress
    5  Version: 1.7.6
     5 Version: 1.7.7
    66 
    77 */
  • tcard-wp/trunk/admin/js/tcard-admin.js

    r1912812 r1912883  
    33 Author: Cloanta Alexandru
    44 Name: Tcard Wordpress
    5  Version: 1.7.6
     5 Version: 1.7.7
    66 
    77 */
  • tcard-wp/trunk/admin/js/tcard-admin.min.js

    r1912812 r1912883  
    33 Author: Cloanta Alexandru
    44 Name: Tcard Wordpress
    5  Version: 1.7.6
     5 Version: 1.7.7
    66 
    77 */
  • tcard-wp/trunk/front/css/tcard.css

    r1912812 r1912883  
    33 Author: Cloanta Alexandru
    44 Name: Tcard Wordpress
    5  Version: 1.7.6
     5 Version: 1.7.7
    66 
    77 */
    8 
    98@import url('https://fonts.googleapis.com/css?family=Lato:300,300i,400,400i,700,700i,900,900i');
    109
  • tcard-wp/trunk/front/css/tcard.min.css

    r1912812 r1912883  
    33 Author: Cloanta Alexandru
    44 Name: Tcard Wordpress
    5  Version: 1.7.6
     5 Version: 1.7.7
    66 
    77 */
  • tcard-wp/trunk/front/css/tcard_color.css

    r1912812 r1912883  
    33 Author: Cloanta Alexandru
    44 Name: Tcard Wordpress
    5  Version: 1.7.6
     5 Version: 1.7.7
    66 
    77 */
  • tcard-wp/trunk/front/css/tcard_color.min.css

    r1912812 r1912883  
    33 Author: Cloanta Alexandru
    44 Name: Tcard Wordpress
    5  Version: 1.7.6
     5 Version: 1.7.7
    66 
    77 */
  • tcard-wp/trunk/front/js/tcard.js

    r1912812 r1912883  
    33 Author: Cloanta Alexandru
    44 Name: Tcard Wordpress
    5  Version: 1.7.6
     5 Version: 1.7.7
    66 
    77 */
  • tcard-wp/trunk/front/js/tcard.min.js

    r1912812 r1912883  
    33 Author: Cloanta Alexandru
    44 Name: Tcard Wordpress
    5  Version: 1.7.6
     5 Version: 1.7.7
    66 
    77 */
  • tcard-wp/trunk/inc/elements-class/TcardSettings.php

    r1912812 r1912883  
    2929                $output = unserialize($output[$skin]->settings);
    3030            }
    31         }else{
    32             $output = "";
    3331        }
    3432
  • tcard-wp/trunk/readme.txt

    r1912813 r1912883  
    137137
    138138== Changelog ==
     139Tcard v1.7.7
     140Change:
     141- File fixed: change TcardTables.php
     142- Bug fixed: unexpected output during activation.
     143
    139144Tcard v1.7.6
    140145Change:
  • tcard-wp/trunk/tcard.php

    r1912812 r1912883  
    55 * Plugin URI:        https://www.addudev.com/tcard
    66 * Description:       Tcard plugin create multiple type of cards: profile, contact, address, login, register etc.
    7  * Version:           1.7.6
     7 * Version:           1.7.7
    88 * Author:            Cloanta Alexandru
    99 * Author URI:        https://www.addudev.com
     
    3939            $this->plugin_name = 'tcard';
    4040
    41             $this->version = '1.7.6';
     41            $this->version = '1.7.7';
    4242
    4343            $this->constants();
Note: See TracChangeset for help on using the changeset viewer.