🔒 EXCLUSIVE: Changeset/ - Full Gallery 2025

Changeset 2703057


Ignore:
Timestamp:
04/01/2022 04:07:31 AM (4 years ago)
Author:
OTWthemes
Message:

Version 1.15

Location:
info-boxes-shortcode-and-widget
Files:
156 added
11 edited

Legend:

Unmodified
Added
Removed
  • info-boxes-shortcode-and-widget/trunk/include/otw_components/otw_factory/otw_factory.class.php

    r2616905 r2703057  
    1818    public function __construct(){
    1919       
    20         if( isset( $_SERVER['DOCUMENT_ROOT'] ) && preg_match( "/webserver\/otw_wp\/home\/web\/(([0-9])\.([0-9])\.([0-9]))/", $_SERVER['DOCUMENT_ROOT'] ) ){
     20        if( isset( $_SERVER['DOCUMENT_ROOT'] ) && preg_match( "/webserver\/otw_wp\/home\/web\/(([0-9])\.([0-9])\.?([0-9])?)/", $_SERVER['DOCUMENT_ROOT'] ) ){
    2121            $this->upd_tm = 0;
    2222            $this->api_url = 'http://otw_wp_api.com/v1/';
  • info-boxes-shortcode-and-widget/trunk/include/otw_components/otw_factory/otw_factory.info.php

    r2616905 r2703057  
    55Description:  OTW Form
    66Author: OTWthemes.com
    7 Version: 5.1
     7Version: 5.2
    88Author URI: http://themeforest.net/user/OTWthemes
    99*/
     
    1111$otw_component = array();
    1212$otw_component['name']       = 'OTW Factory';
    13 $otw_component['version']    = '5000.1';
     13$otw_component['version']    = '5000.2';
    1414$otw_component['class_name'] = 'OTW_Factory';
    1515?>
  • info-boxes-shortcode-and-widget/trunk/include/otw_components/otw_form/otw_form.class.php

    r2616905 r2703057  
    222222                    }
    223223                    $html .= "</div>";
     224                break;
     225            case 'wpui':
     226                    $html .= "<select ".self::format_attributes( array('id','name','class','style', 'data-reload'), array(), $attributes )." ".$attributes['extra'].">";
     227                   
     228                    foreach( $attributes['options'] as $key => $value ){
     229                        $selected = "";
     230                       
     231                        if( strnatcasecmp( $key, $attributes['value'] ) === 0 ){
     232                            $selected = " selected=\"selected\"";
     233                        }
     234                        $html .= "<option value=\"".$key."\"".$selected.">".$value."</option>";
     235                    }
     236                    $html .= "</select>";
    224237                break;
    225238            default:
  • info-boxes-shortcode-and-widget/trunk/include/otw_components/otw_form/otw_form.info.php

    r2616905 r2703057  
    55Description:  OTW Form
    66Author: OTWthemes.com
    7 Version: 9.3
     7Version: 9.4
    88Author URI: http://themeforest.net/user/OTWthemes
    99*/
     
    1111$otw_component = array();
    1212$otw_component['name']       = 'OTW Form';
    13 $otw_component['version']    = '9000.3';
     13$otw_component['version']    = '9000.4';
    1414$otw_component['class_name'] = 'OTW_Form';
    1515?>
  • info-boxes-shortcode-and-widget/trunk/include/otw_components/otw_functions/otw_functions.php

    r2616905 r2703057  
    604604                    $value = sanitize_textarea_field( $value );
    605605                break;
     606            case 'integer':
     607                    if( !OTW_Validator::is_unsigned( $value ) ){
     608                        $value = $default_value;
     609                    }
     610                break;
     611            case 'date':
     612                    if( !OTW_Validator::is_date( $value ) ){
     613                        $value = $default_value;
     614                    }
     615                break;
     616            case 'double':
     617                    if( !OTW_Validator::is_double( $value ) ){
     618                        $value = $default_value;
     619                    }
     620                break;
    606621            default:
    607622                    if( is_array( $value ) || is_object( $value ) ){
  • info-boxes-shortcode-and-widget/trunk/include/otw_components/otw_shortcode/js/otw_shortcode_admin.js

    r2616905 r2703057  
    354354        otw_form_init_fields();
    355355       
    356         var fields = {};
    357        
    358         var code = '';
     356        oSelf.fields = {};
     357       
     358        oSelf.code = '';
    359359       
    360360        oSelf.init_fields();
  • info-boxes-shortcode-and-widget/trunk/include/otw_components/otw_shortcode/otw_shortcode.class.php

    r2616905 r2703057  
    227227               
    228228                if( function_exists( 'register_block_type' ) ){
    229                     register_block_type( 'otw-shortcode-component/otw-shortcode-block', array( 'editor_script' => 'otw-shortcode-block-editor' ) );
     229                    if( !WP_Block_Type_Registry::get_instance()->is_registered( 'otw-shortcode-component/otw-shortcode-block' ) ){
     230                        register_block_type( 'otw-shortcode-component/otw-shortcode-block', array( 'editor_script' => 'otw-shortcode-block-editor' ) );
     231                    }
    230232                }
    231233            }
  • info-boxes-shortcode-and-widget/trunk/include/otw_components/otw_validator/otw_validator.class.php

    r2616905 r2703057  
    4646        return false;
    4747    }
     48   
     49    /**
     50     * check if given string is a date with format YYYY-mm-dd
     51     *
     52     * @param string
     53     *
     54     * @return boolean
     55     */
     56    public static function is_date( $string ){
     57       
     58        if( preg_match( "/^\d{4}\-\d{2}\-\d{2}$/", $string, $matches ) ){
     59            return true;
     60        }
     61        return false;
     62    }
     63   
     64    /**
     65     * check if given string is doubleinterger
     66     *
     67     * @param string
     68     *
     69     * @return boolean
     70     */
     71    public static function is_double( $string ){
     72       
     73        if( is_numeric( $string ) ){
     74            return true;
     75        }
     76        return false;
     77    }
    4878}
  • info-boxes-shortcode-and-widget/trunk/include/otw_components/otw_validator/otw_validator.info.php

    r2616905 r2703057  
    55Description:  OTW Validator
    66Author: OTWthemes.com
    7 Version: 2.1
     7Version: 2.2
    88Author URI: http://themeforest.net/user/OTWthemes
    99*/
     
    1111$otw_component = array();
    1212$otw_component['name']       = 'OTW Validator';
    13 $otw_component['version']    = '2000.1';
     13$otw_component['version']    = '2000.2';
    1414$otw_component['class_name'] = 'OTW_Validator';
    1515?>
  • info-boxes-shortcode-and-widget/trunk/otw_content_manager.php

    r2616905 r2703057  
    55Description:  Create Inbo Boxes. Nice and easy interface. Insert anywhere in your site - page/post editor, sidebars, template files.
    66Author: OTWthemes
    7 Version: 1.14
     7Version: 1.15
    88Author URI: https://codecanyon.net/user/otwthemes/portfolio?ref=OTWthemes
    99*/
  • info-boxes-shortcode-and-widget/trunk/readme.txt

    r2616905 r2703057  
    44Tags: infobox, info boxes, shortcode, widgets, button, WYSIWYG editor, widget, sidebar
    55Requires at least: 3.6
    6 Tested up to: 5.8.1
    7 Stable tag: 1.14
     6Tested up to: 5.9
     7Stable tag: 1.15
    88License: GPLv2 or later
    99License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    8282== Changelog ==
    8383
     84= 1.15 =
     85
     86* Fixed: Validation for registered block editors
     87* Fixed: Dynamic shortcode fields
     88* Updated: Core components
     89
    8490= 1.14 =
    8591
Note: See TracChangeset for help on using the changeset viewer.