Plugin Directory

Changeset 1528830


Ignore:
Timestamp:
11/05/2016 03:36:17 PM (9 years ago)
Author:
O-Zone
Message:

tagging 0.8.2

Location:
wp-allaround
Files:
6 edited
2 copied

Legend:

Unmodified
Added
Removed
  • wp-allaround/tags/0.6.1/README.txt

    r1462090 r1528830  
    55Requires at least: 4.0.0
    66Tested up to: 4.6.0
    7 Stable tag: 0.6
     7Stable tag: 0.6.1
    88License: GPLv2 or later
    99License URI: http://www.gnu.org/licenses/gpl-2.0.html
  • wp-allaround/tags/0.6.1/wp-allaround.php

    r1464978 r1528830  
    44Plugin URI:     http://www.allaroundsiena.com/plugin
    55Description:    This plugin let you to connect a Telegram Bot with your blog
    6 Version:    0.6
     6Version:    0.6.1
    77Author:     Michele Pinassi
    88Author URI: http://www.zerozone.it
     
    7777?>
    7878    <p>
    79         <input type="checkbox" name="allaround_post_do_publish" id="allaround_post_do_publish" value="1" checked/>
    80         <label class="description" for="allaround_post_do_publish"><?php _e('Publish this post on AllAround', 'wp-allaround' ); ?></label>
     79        <input type="checkbox" name="allaround_post_publish" id="allaround_post_publish" value="1" checked />
     80        <label class="description" for="allaround_post_publish"><?php _e('Publish this post on AllAround', 'wp-allaround' ); ?></label>
    8181    </p>
    8282<?php
     
    133133    $option_api_key = get_option( 'allaround_api_key' );
    134134
    135 //  if(($option_api_key) && ('publish' === $new_status && 'publish' !== $old_status)) {
    136 
    137135    if($option_api_key) {
    138136        /* Get the post properties */
     
    187185}
    188186
    189 add_action('publish_post','allaround_action_publish',10,2);
    190 
    191 function allaround_action_publish($ID, $post) {
     187// add_action('transition_post_status', 'allaround_post_publish', 10, 3);
     188
     189add_action('save_post','allaround_post_publish', 10, 3);
     190
     191function allaround_post_publish($ID, $post, $update) {
     192
    192193    /* Check if this post was already published to avoid duplicates */
    193194    $check_is_publish = get_post_meta($post->ID,'allaround_post_publish', true);
  • wp-allaround/tags/0.8.2/README.txt

    r1519139 r1528830  
    55Requires at least: 4.0.0
    66Tested up to: 4.6.1
    7 Stable tag: 0.8.1
     7Stable tag: 0.8.2
    88License: GPLv2 or later
    99License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    3535
    3636== Changelog ==
     37
     38= 0.8.2 =
     39* Fixed a nasty bug that cause an error while installing the plugin on older PHP version
    3740
    3841= 0.8.1 =
  • wp-allaround/tags/0.8.2/wp-allaround.php

    r1519139 r1528830  
    44Plugin URI:     http://www.allaroundsiena.com/plugin
    55Description:    This plugin let you to connect a Telegram Bot with your blog
    6 Version:    0.8.1
     6Version:    0.8.2
    77Author:     Michele Pinassi
    88Author URI: http://www.zerozone.it
     
    9595        printf( __('Error %s while publishing on %s', 'wp-allaround'), $post_message, $t_date);
    9696?>
    97         <p>
    98         <input type="checkbox" name="allaround_post_do_publish" id="allaround_post_do_publish" value="1"/>
    99         <label class="description" for="allaround_post_do_publish"><?php _e('Try again', 'wp-allaround' ); ?></label>
    100         </p>
     97    <p>
     98        <input type="checkbox" name="allaround_post_publish" id="allaround_post_publish" value="1" checked />
     99        <label class="description" for="allaround_post_publish"><?php _e('Publish this post on AllAround', 'wp-allaround' ); ?></label>
     100    </p>
    101101<?php
    102102
     
    185185    /* Post have an image ? */
    186186    if(has_post_thumbnail($post->ID)) {
    187         $post_image_url = wp_get_attachment_image_src(get_post_thumbnail_id($post->ID), 'medium')[0];
     187        $post_image = wp_get_attachment_image_src(get_post_thumbnail_id($post->ID), 'medium');
     188        $post_image_url = $post_image[0];
    188189    } else {
    189190        $post_image_url = '';
     
    232233}
    233234
    234 /* ============================================================ */
    235 /*                              */
    236 /* PUBLISH HOOK                         */
    237 /*                              */
    238 /* =============================================================*/
    239 
    240 function allaround_action_publish($new_status, $old_status, $post) {
    241     $do_publish = false;
     235// add_action('transition_post_status', 'allaround_post_publish', 10, 3);
     236
     237add_action('save_post','allaround_post_publish', 10, 3);
     238
     239function allaround_post_publish($ID, $post, $update) {
     240
     241    /* Check if this post was already published to avoid duplicates */
     242    $check_is_publish = get_post_meta($post->ID,'allaround_post_publish', true);
    242243
    243244    error_log("FIRED: allaround_action_publish($new_status,$old_status,$post->ID)");
  • wp-allaround/trunk/README.txt

    r1519139 r1528830  
    55Requires at least: 4.0.0
    66Tested up to: 4.6.1
    7 Stable tag: 0.8.1
     7Stable tag: 0.8.2
    88License: GPLv2 or later
    99License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    3535
    3636== Changelog ==
     37
     38= 0.8.2 =
     39* Fixed a nasty bug that cause an error while installing the plugin on older PHP version
    3740
    3841= 0.8.1 =
  • wp-allaround/trunk/wp-allaround.php

    r1519139 r1528830  
    44Plugin URI:     http://www.allaroundsiena.com/plugin
    55Description:    This plugin let you to connect a Telegram Bot with your blog
    6 Version:    0.8.1
     6Version:    0.8.2
    77Author:     Michele Pinassi
    88Author URI: http://www.zerozone.it
     
    9595        printf( __('Error %s while publishing on %s', 'wp-allaround'), $post_message, $t_date);
    9696?>
    97         <p>
    98         <input type="checkbox" name="allaround_post_do_publish" id="allaround_post_do_publish" value="1"/>
    99         <label class="description" for="allaround_post_do_publish"><?php _e('Try again', 'wp-allaround' ); ?></label>
    100         </p>
     97    <p>
     98        <input type="checkbox" name="allaround_post_publish" id="allaround_post_publish" value="1" checked />
     99        <label class="description" for="allaround_post_publish"><?php _e('Publish this post on AllAround', 'wp-allaround' ); ?></label>
     100    </p>
    101101<?php
    102102
     
    185185    /* Post have an image ? */
    186186    if(has_post_thumbnail($post->ID)) {
    187         $post_image_url = wp_get_attachment_image_src(get_post_thumbnail_id($post->ID), 'medium')[0];
     187        $post_image = wp_get_attachment_image_src(get_post_thumbnail_id($post->ID), 'medium');
     188        $post_image_url = $post_image[0];
    188189    } else {
    189190        $post_image_url = '';
     
    232233}
    233234
    234 /* ============================================================ */
    235 /*                              */
    236 /* PUBLISH HOOK                         */
    237 /*                              */
    238 /* =============================================================*/
    239 
    240 function allaround_action_publish($new_status, $old_status, $post) {
    241     $do_publish = false;
     235// add_action('transition_post_status', 'allaround_post_publish', 10, 3);
     236
     237add_action('save_post','allaround_post_publish', 10, 3);
     238
     239function allaround_post_publish($ID, $post, $update) {
     240
     241    /* Check if this post was already published to avoid duplicates */
     242    $check_is_publish = get_post_meta($post->ID,'allaround_post_publish', true);
    242243
    243244    error_log("FIRED: allaround_action_publish($new_status,$old_status,$post->ID)");
Note: See TracChangeset for help on using the changeset viewer.