Plugin Directory

Changeset 837104


Ignore:
Timestamp:
01/12/2014 12:07:22 PM (12 years ago)
Author:
rvwoens
Message:

php 5.2 and version checks

Location:
map-pins/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • map-pins/trunk/map-pins.php

    r836923 r837104  
    44 * Plugin URI: http://mappins.innovader.nl
    55 * Description: Show pins on a map from an admin defined table
    6  * Version: 1.0
     6 * Version: 1.01
    77 * Author: Innovader BV
    88 * Author URI: http://innovader.nl
     
    1414define('MAPPINS_PICS_URL', MAPPINS_PLUGIN_URL.'/pics');
    1515define('MAPPINS_PICS_DIR', MAPPINS_PLUGIN_DIR.'/pics');
     16define('MINIMAL_PHP_VERSION','5.2.4');
    1617
    1718require (MAPPINS_PLUGIN_DIR.'/include/xcos.php');       // helpers
     
    5152function mappins_install() {
    5253    global $wpdb;
     54   
     55    if ( version_compare( PHP_VERSION, MINIMAL_PHP_VERSION, '<' ) ) {
     56        deactivate_plugins( basename( __FILE__ ) );
     57        wp_die('<p>The <strong>map-pins</strong> plugin requires PHP version '.MINIMAL_PHP_VERSION.' or greater.</p>','Plugin Activation Error',  array( 'response'=>200, 'back_link'=>TRUE ) );
     58        return;
     59    }
     60
    5361    $table_name = $wpdb->prefix . "mappins_markers";
    5462    $sql = "
  • map-pins/trunk/readme.txt

    r836926 r837104  
    8484= 0.1 =
    8585* Initial release.
    86 = 0.2 =
     86= 1.0 =
    8787* After hours notification with moon icon
    8888* screenshots and other nice info on wordpress.org
    8989* made responsive
     90= 1.01 =
     91* php 5.2 compatible and php version check
    9092
    9193== Upgrade Notice ==
    9294
    9395= 0.1 =
    94 * Initial release.
     96* Initial release
     97= 1.0 =
     98* release on wordpress.org
     99= 1.01 =
     100* bugfixes
    95101
     102
     103
Note: See TracChangeset for help on using the changeset viewer.