WordPress.org

Plugin Directory

Changeset 1629181


Ignore:
Timestamp:
04/04/17 12:40:21 (8 months ago)
Author:
bobbingwide
Message:

v0.2.2 - tested with WordPress 4.7.3, tested with PHP 7.1, now depends on oik v3.1 or higher

Location:
oik-read-more/trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • oik-read-more/trunk/admin/oik-activation.php

    r1308298 r1629181  
    1 <?php // (C) Copyright Bobbing Wide 2012-2015 
    2  
    3 /** 
    4  *  
    5  * @TODO This logic has been converted to a shared library in libs/oik-activation.php 
    6  */ 
     1<?php // (C) Copyright Bobbing Wide 2012-2016 
     2if ( !defined( "OIK_ACTIVATION_INCLUDED" ) ) { 
     3define( "OIK_ACTIVATION_INCLUDED", "3.1.0" ); 
     4 
    75 
    86if ( function_exists( "oik_plugin_lazy_activation" ) ) { 
     
    1311 * Produce an install plugin link 
    1412 * 
    15  * @param string $plugin 
    16  * @return string the install plugin link 
     13 * @param string $plugin plugin slug 
     14 *  
     15 * @return string link for the plugin install 
    1716 */ 
    1817function oik_plugin_install_plugin( $plugin ) { 
     
    3534 * @return string link to enable activation - which user must choose 
    3635 * We probably don't need plugin_status OR paged parameters 
    37   
     36 * 
    3837 * ` 
    3938   http://example.com/wp-admin/plugins.php? 
     
    5756}  
    5857  
    59 /**     
    60     $path = "update.php?action=install-plugin&plugin=$plugin"; 
    61     $url = admin_url( $path ); 
    62     $url = wp_nonce_url( $url, "install-plugin_oik" );  
    63     $link = '<a href="'; 
    64     $link .= $url; 
    65     $link .= '">Install oik</a>'; 
    66      
    67   $url = wp_nonce_url(self_admin_url('update.php?action=upgrade-plugin&plugin=' . $update_file), 'upgrade-plugin_' . $update_file); 
     58/** 
     59 * Create an Update plugin link 
     60 * 
     61 * Decided to use "Update" rather than " Upgrade".  
     62 * 
     63 * @param string $plugin the plugin slug 
     64 * @return string the update link 
    6865 */ 
    6966function oik_plugin_update_plugin( $plugin ) { 
     
    7471  $link .= $url; 
    7572  $link .= '">';  
    76   $link .= __(' Upgrade' ); 
     73  $link .= __( 'Update' ); 
    7774  $link .= " $plugin</a>"; 
    7875  return( $link ); 
     
    8178/**  
    8279 * Find out if we think the plugin is installed but not activated or not even installed 
     80 *  
    8381 * @param string $plugin - the plugin file name ( without plugin path info? ) 
    8482 * @return string - null if it's not installed or plugin to be activated 
     
    125123 
    126124/** 
     125 * Test if the plugin is activated 
     126 * 
    127127 * This won't work for Multisite since it doesn't find the network activated plugins 
    128128 * Even if it did, the admin may not be able to do anything. 
     
    231231 
    232232 
     233/** 
     234 * Simple implementation of plugin dependency logic 
     235 * 
     236 * @param string $plugin - the plugin file name 
     237 * @param string $dependencies - the list of plugins upon which this plugin is dependent 
     238 * @param string $callback - the callback function to invoke when the dependencies aren't satisfied 
     239 * 
     240 * Instead of calling this module during activation we invoke it in response to the  
     241 * after_plugin_row_$plugin_basename action. 
     242 *  
     243 * This gives us a bit more control over the information we provide. 
     244 * IF the oik plugin is not activated then oik_lazy_depends() will not be defined 
     245 *  
     246 */ 
     247if ( !function_exists( "oik_depends" ) ) { 
     248function oik_depends( $plugin=null, $dependencies="oik", $callback=null ) { 
     249  //bw_trace2(); 
     250  //if ( function_exists( "oik_load_plugins" )) { 
     251  //  oik_load_plugins(); 
     252  //}   
     253  if ( function_exists( "oik_lazy_depends" ) ) {   
     254    oik_lazy_depends( $plugin, $dependencies, $callback ); 
     255  } else { 
     256    if ( is_callable( $callback ) ) { 
     257      call_user_func( $callback, $plugin, $dependencies, "missing" ); 
     258    }   
     259  }   
     260} 
     261} 
     262 
     263 
    233264} // end else  
     265 
     266} // end if !defined()  
  • oik-read-more/trunk/oik-read-more.php

    r1308298 r1629181  
    22/* 
    33Plugin Name: oik-read-more 
    4 Plugin URI: http://www.oik-plugins.com/oik-plugins/oik-read-progressively-reveal-content/ 
     4Plugin URI: https://www.oik-plugins.com/oik-plugins/oik-read-progressively-reveal-content/ 
    55Description: Implements [bw_more] shortcode to progressively reveal content 
    6 Version: 0.2.1   
     6Version: 0.2.2   
    77Author: bobbingwide 
    8 Author URI: http://www.oik-plugins.com/author/bobbingwide 
     8Author URI: https://www.oik-plugins.com/author/bobbingwide 
    99Text Domain: oik-read-more 
    1010Domain Path: /languages/ 
     
    1212License URI: http://www.gnu.org/licenses/gpl-2.0.html 
    1313 
    14     Copyright 2014,2015 Bobbing Wide (email : herb@bobbingwide.com ) 
     14    Copyright 2014-2017 Bobbing Wide (email : herb@bobbingwide.com ) 
    1515 
    1616    This program is free software; you can redistribute it and/or modify 
     
    6060    } 
    6161  }   
    62   $depends = "oik:2.5"; 
     62  $depends = "oik:3.1"; 
    6363  oik_plugin_lazy_activation( __FILE__, $depends, "oik_plugin_plugin_inactive" ); 
    6464} 
  • oik-read-more/trunk/readme.txt

    r1308298 r1629181  
    11=== oik-read-more === 
    22Contributors: bobbingwide, vsgloik 
    3 Donate link: http://www.oik-plugins.com/oik/oik-donate/ 
    4 Tags: shortcodes, smart, lazy, [bw_more] 
     3Donate link: https://www.oik-plugins.com/oik/oik-donate/ 
     4Tags: shortcode, [bw_more], oik 
    55Requires at least: 3.9 
    6 Tested up to: 4.4 
    7 Stable tag: 0.2.1 
     6Tested up to: 4.7.3 
     7Stable tag: 0.2.2 
    88License: GPLv2 or later 
    99License URI: http://www.gnu.org/licenses/gpl-2.0.html 
     
    2424 
    2525 
    26 == Installation == 
     26== Frequently Asked Questions == 
     27 
     28= Installation = 
    27291. Upload the contents of the oik-read-more plugin to the `/wp-content/plugins/oik-read-more' directory 
    28301. Activate the oik-read-more plugin through the 'Plugins' menu in WordPress 
    2931 
    30 == Frequently Asked Questions == 
     32Note: You will also need the oik base plugin, version 3.1 or higher. 
     33 
    3134= Is it dependent upon oik? = 
    3235Yes. It depends on the oik base plugin. 
     
    4548Use custom CSS to style the 'read more' text. 
    4649 
     50= Further reading = 
     51If you want to read more about the oik plugins then please visit the 
     52[oik plugin](https://www.oik-plugins.com/oik)  
     53**"the oik plugin - for often included key-information"** 
    4754 
    4855 
     
    5259 
    5360== Upgrade Notice == 
     61= 0.2.2 =  
     62Tested with WordPress 4.7.3 and WordPress Multisite. Tested with PHP 7.1. Now depends on oik v3.1 or higher. 
     63 
    5464= 0.2.1 =  
    5565Tested with WordPress 4.4 and WordPress Multisite. Now depends on oik v2.5 or higher 
     
    6272 
    6373== Changelog == 
     74= 0.2.2 = 
     75* Changed: Depends on oik v3.1 or higher  
     76* Tested: With WordPress 4.7.3 and WordPress Multisite 
     77* Tested: With PHP 7.1 
     78 
    6479= 0.2.1 =  
    6580* Changed: Depends on oik v2.5 or higher 
     
    7489* Added: New plugin implementing the [bw_more] shortcode 
    7590 
    76 == Further reading == 
    77 If you want to read more about the oik plugins then please visit the 
    78 [oik plugin](http://www.oik-plugins.com/oik)  
    79 **"the oik plugin - for often included key-information"** 
    80  
Note: See TracChangeset for help on using the changeset viewer.