Plugin Directory

Changeset 1952575


Ignore:
Timestamp:
10/06/2018 12:38:00 PM (7 years ago)
Author:
ahmadasjad
Message:

php session start correc

Location:
custom-design-product/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • custom-design-product/trunk/README.txt

    r1582763 r1952575  
    77Author URI: https://profiles.wordpress.org/ahmadasjad
    88Requires at least: 4.6
    9 Tested up to: 4.7
    10 Stable tag: 1.3
     9Tested up to: 4.8.9
     10Stable tag: 1.4
    1111License: GPLv2 or later
    1212License URI: http://www.gnu.org/licenses/gpl-2.0.html
  • custom-design-product/trunk/custom-print.php

    r1582932 r1952575  
    1414
    1515function wcdp_register_session() {
    16     if (!session_id()) {
     16    if(version_compare(PHP_VERSION, '5.4.0', '>=') && session_status() === PHP_SESSION_NONE){
     17        session_start();
     18    }elseif (version_compare(PHP_VERSION, '5.4.0', '<') && !session_id()) {
    1719        session_start();
    1820    }
    1921}
    2022
    21 //add_action('init', 'wcdp_register_session');
     23add_action('init', 'wcdp_register_session');
    2224
    2325require_once dirname(__FILE__) . '/meta_box.php';
Note: See TracChangeset for help on using the changeset viewer.