Changeset 1847196
- Timestamp:
- 03/26/2018 06:02:35 PM (8 years ago)
- Location:
- pushnews/trunk
- Files:
-
- 4 edited
-
CHANGELOG.md (modified) (1 diff)
-
class.pushnews.php (modified) (3 diffs)
-
pushnews.php (modified) (3 diffs)
-
readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
pushnews/trunk/CHANGELOG.md
r1840266 r1847196 1 1 CHANGELOG 2 2 ========= 3 # 1.5.1 4 - Fixed some issues regarding the automatic push notifications 5 3 6 # 1.5.0 4 7 - Added send automatic push mail feature on new post publish -
pushnews/trunk/class.pushnews.php
r1840266 r1847196 23 23 24 24 class Pushnews { 25 const VERSION = '1.5. 0';25 const VERSION = '1.5.1'; 26 26 const RESOURCES_VERSION = '1'; 27 27 const API_URL = 'https://app.pushnews.eu/api.php/v1'; … … 89 89 } 90 90 91 function save_post_custom_hook($post_id, $post, $update)91 function publish_post_custom_hook($post_id, $post) 92 92 { 93 93 $sendNotification = $_POST['pushnews_send_notification']; … … 95 95 $options = get_option( 'pushnews_options' ); 96 96 97 if( !$update&& isset($options['auth_token']) && $options['auth_token'] != "") {97 if($post->post_date == $post->post_modified && isset($options['auth_token']) && $options['auth_token'] != "") { 98 98 $notification = array( 99 99 "message" => array( -
pushnews/trunk/pushnews.php
r1840266 r1847196 6 6 * Plugin URI: https://www.pushnews.eu/ 7 7 * Description: Send Web Push Notifications to your visitors. Increase your website traffic - Simple and fast UI - Automate push notifications via Facebook Page integration. 8 * Version: 1.5. 08 * Version: 1.5.1 9 9 * Author URI: https://www.pushnews.eu/ 10 10 * License: GPLv2 or later … … 29 29 */ 30 30 31 define( 'PUSHNEWS_VERSION', '1.5. 0' );31 define( 'PUSHNEWS_VERSION', '1.5.1' ); 32 32 define( 'PUSHNEWS__PLUGIN_DIR', plugin_dir_path( __FILE__ ) ); 33 33 … … 48 48 // Send push on post publish 49 49 add_action( "add_meta_boxes", array( 'Pushnews', "add_custom_meta_box" )); 50 add_action( " save_post", array('Pushnews', 'save_post_custom_hook' ), 10, 3);50 add_action( "publish_post", array('Pushnews', 'publish_post_custom_hook' ), 10, 2 ); -
pushnews/trunk/readme.txt
r1840266 r1847196 6 6 Tested up to: 4.9.4 7 7 Requires PHP: 5.3 8 Stable tag: 1.5. 08 Stable tag: 1.5.1 9 9 License: GPLv2 or later 10 10 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 60 60 61 61 == Changelog == 62 = 1.5.1 = 63 * Fixed some issues regarding the automatic push notifications 64 62 65 = 1.5.0 = 63 66 * Added send automatic push mail feature on new post publish
Note: See TracChangeset
for help on using the changeset viewer.