diff --git a/images/SampleNotification.png b/images/SampleNotification.png deleted file mode 100644 index 83d80d8..0000000 Binary files a/images/SampleNotification.png and /dev/null differ diff --git a/onesignal-admin.php b/onesignal-admin.php index 3324e1e..e498043 100644 --- a/onesignal-admin.php +++ b/onesignal-admin.php @@ -160,6 +160,7 @@ public static function notification_on_blog_post( $new_status, $old_status, $pos 'app_id' => $onesignal_wp_settings['app_id'], 'included_segments' => array('All'), 'isChromeWeb' => true, + 'url' => get_permalink(), 'contents' => array("en" => $notif_content) ); diff --git a/onesignal.php b/onesignal.php index d652fa3..5bcfca0 100644 --- a/onesignal.php +++ b/onesignal.php @@ -3,7 +3,7 @@ * Plugin Name: OneSignal Push Notifications * Plugin URI: https://onesignal.com/ * Description: - * Version: 1.0.3 + * Version: 1.0.4 * Author: OneSignal * Author URI: https://onesignal.com * License: MIT diff --git a/readme.txt b/readme.txt index bd05006..6504421 100644 --- a/readme.txt +++ b/readme.txt @@ -3,8 +3,8 @@ Contributors: OneSignal Donate link: https://onesignal.com Tags: chrome, push, push notifications, safari, chrome push, safari push, notifications, web push, notification, notify, mavericks, firefox push, android, android push, android notifications, mobile notifications, mobile, desktop notifications, gcm, push messages, onesignal Requires at least: 3.8 -Tested up to: 4.2.1 -Stable tag: 1.0.3 +Tested up to: 4.3 +Stable tag: 1.0.4 License: GPLv2 or later License URI: http://www.gnu.org/licenses/gpl-2.0.html @@ -12,13 +12,13 @@ Increase engagement and drive more repeat traffic to your WordPress site with de == Description == -[OneSignal](https://onesignal.com) is a complete push notification solution for WordPress blogs and sites, trusted by over 2400 developers and marketers including some of the largest brands and websites in the world. +[OneSignal](https://onesignal.com) is a complete push notification solution for WordPress blogs and sites, trusted by over 5000 developers and marketers including some of the largest brands and websites in the world. After just a few seconds of set-up, your visitors will be able to opt-in to receive desktop push notifications when you publish a new post. OneSignal makes use of a brand new Google Chrome feature to send desktop notifications to your visitors even after they’ve left your website. OneSignal makes it easy to configure when to send notifications, target notifications to specific users, and to customize the Opt-In process for your visitors. -Best of all, for a limited time, all WordPress users that use OneSignal will get a FREE lifetime account. +Best of all, WordPress users that use OneSignal will get a FREE lifetime account. Features: @@ -46,14 +46,18 @@ Features: == Changelog == += 1.0.4 = +- Notifications sent with the Automatic Push Notifications on Post feature directly link to the post instead of the homepage when opening the notification. +- Updated GCM instructions and added HTTP subscribe link/widget instructions on the Getting Started tab. + = 1.0.3 = -Fixed compatibility issue with PHP versions older than 5.3.0 -For HTTPS sites a modal dialog is shown before the native Chrome Notification permission prompt. +- Fixed compatibility issue with PHP versions older than 5.3.0 +- For HTTPS sites a modal dialog is shown before the native Chrome Notification permission prompt. = 1.0.2 = -Fixed bug with OneSignal not getting initialized in some cases. -Now omits extra unneeded manifest link from the head tag when using HTTP. -Clicks handler added to elements with the class OneSignal-prompt are now setup in a more compatible way. +- Fixed bug with OneSignal not getting initialized in some cases. +- Now omits extra unneeded manifest link from the head tag when using HTTP. +- Clicks handler added to elements with the class OneSignal-prompt are now setup in a more compatible way. = 1.0.1 = Modified description diff --git a/views/config.php b/views/config.php index f055ced..60d5e6c 100644 --- a/views/config.php +++ b/views/config.php @@ -51,16 +51,17 @@
Go to onesignal.com and create a new account. After verifying your account, sign in and create a new OneSignal app.
- "> + " style="width: 80%">2.1: Create a project at https://console.developers.google.com/project for your app.
- "> + " style="width: 80%"> + " style="width: 80%"> -2.2: Select your Project and click on "Overview." Your project number should be located on this page.
- "> +2.2: Once your project has finished creating, select your project and click on Overview. Your project number should be located on this page.
+ " style="width: 80%">Save the Project Number: You will need this number shortly when you configure your OneSignal app.
@@ -69,59 +70,70 @@STEP 3: Turn on both "Google Cloud Messaging for Chrome" and "Google Cloud Messaging for Android" APIs
+3.1: Under APIs & auth > APIs, search for Google Cloud Messaging for Chrome. Turn it on. You will need this for desktop notifications.
-2.3: Turn on both "Google Cloud Messaging for Chrome" and "Google Cloud Messaging for Android" APIs
-Under APIs & auth>APIs, search for "Google Cloud Messaging for Chrome." Turn it on. You will need this for desktop notifications.
-Search for "Google Cloud Messaging for Android" and turn it on. You need this so an Chrome browser running on Android can send system notifications to the user.
+ " style="width: 80%"> + " style="width: 80%"> + " style="width: 80%"> - "> - "> - "> +STEP 4: Create and save Server Key
+4.1: Under APIs & auth > Credentials, click the Add credentials button, and click API key.
+ " style="width: 80%"> -2.4: Create and save a Server Key
-Under "APIs & auth" > "Credentials", Click "CREATE NEW KEY".
- "> +4.2: Select "Server key"
+ " style="width: 80%"> -Select "Server key"
- "> +4.3: Without entering any values into the textbox, press the Create button.
+ " style="width: 80%"> -Press the Create button. Leave the IP addresses box empty
- "> - -Copy the "API Key." This is your Google Server API Key. You will need it to configure your project with OneSignal
- "> +4.4: Copy the API Key. You will need it to enter it to the Google Server API Key field in your App Settings.
+ " style="width: 80%">3.1: Log into OneSignal. In the dashboard, select "Application Settings" then press the "Configure" button to the right of "Chrome Website (GCM)".
- "> - -3.2: Paste your Google Server API Key in here and press Save.
- "> - - -3.3: Fill in the remaining fields:
- "> -Why do I need to choose a Subdomain Name? Chrome Push Notifications only work on HTTPS websites. Because most WordPress sites are on HTTP, we send notifications through our HTTPS site using your desired subdomain. Users will see notifications sent from: "your-subdomain.onesignal.com"
-What if I'm already on HTTPS? If your site is already on HTTPS, you don't have to do anything! You can leave the Subdomain field blank.
-Choosing a Subdomain: Users will see this subdomain on every notification, so keep it recognizable! We recommend using your site's name as the subdomain. For example, if your subdomain were "ilikemuskrats," we would send notifications from https://ilikemuskrats.onesignal.com.
-This is your WordPress site's URL.
-ex: www.myWordPressSite.com
-This can be retrieved in Step 2.2
-5.1: Log into OneSignal. In the dashboard, select Application Settings then press the Configure button to the right of Chrome Website (GCM).
+5.2: Paste your Google API Key in here.
+ " style="width: 80%"> + " style="width: 80%"> + +5.3: Fill in the remaining HTTP fields and press Save.
+(Skip these fields if your site is HTTPS)
+6.1: On HTTP sites you can not auto prompt for push notifications. You need to supply either a link/button or add our widget to your site.
+ Option 1 Widget: This provides a quick and easy way to add an opt-in option for push notifications.
Under Appearance > Widgets drag the OneSignal Widget from the list on the left to the Widget Area on the right. You can customize the widget title and body to your liking.
Option 2 CSS Class: Assign the class "OneSignal-prompt" to any link or button element.
Example:
6.2: Test your subcribe link by clicking on the link, button, or widget.
+Why do I need to choose a Subdomain Name? Chrome Push Notifications only work on HTTPS websites. Because most WordPress sites are on HTTP, we send notifications through our HTTPS site using your desired subdomain. Users will see notifications sent from: "your-subdomain.onesignal.com"
+What if I'm already on HTTPS? If your site is already on HTTPS, you don't have to do anything! You can leave the Subdomain field blank.
+Choosing a Subdomain: Users will see this subdomain on every notification, so keep it recognizable! We recommend using your site's name as the subdomain. For example, if your subdomain were "ilikemuskrats," we would send notifications from https://ilikemuskrats.onesignal.com.
+This is your WordPress site's URL.
+ex: www.myWordPressSite.com
+This can be retrieved in Step 2.2
+Congratulations! The next step is to configure your OneSignal Plugin's Account Settings, which only takes a minute.
diff --git a/views/images/settings/app_id-1.jpg b/views/images/settings/app_id-1.jpg deleted file mode 100644 index 9683192..0000000 Binary files a/views/images/settings/app_id-1.jpg and /dev/null differ diff --git a/views/images/settings/app_id_instructions.jpg b/views/images/settings/app_id_instructions.jpg deleted file mode 100644 index e457477..0000000 Binary files a/views/images/settings/app_id_instructions.jpg and /dev/null differ diff --git a/views/images/settings/create-2.jpg b/views/images/settings/create-2.jpg deleted file mode 100644 index 6f18735..0000000 Binary files a/views/images/settings/create-2.jpg and /dev/null differ diff --git a/views/images/settings/gcm-1-2.jpg b/views/images/settings/gcm-1-2.jpg new file mode 100644 index 0000000..c70b228 Binary files /dev/null and b/views/images/settings/gcm-1-2.jpg differ diff --git a/views/images/settings/gcm-1.jpg b/views/images/settings/gcm-1.jpg index 3fb7845..71d8932 100644 Binary files a/views/images/settings/gcm-1.jpg and b/views/images/settings/gcm-1.jpg differ diff --git a/views/images/settings/gcm-10.jpg b/views/images/settings/gcm-10.jpg index 9bd05b8..c19bc82 100644 Binary files a/views/images/settings/gcm-10.jpg and b/views/images/settings/gcm-10.jpg differ diff --git a/views/images/settings/gcm-11.jpg b/views/images/settings/gcm-11.jpg index 12c796d..670861c 100644 Binary files a/views/images/settings/gcm-11.jpg and b/views/images/settings/gcm-11.jpg differ diff --git a/views/images/settings/gcm-12.jpg b/views/images/settings/gcm-12.jpg deleted file mode 100644 index 3b88774..0000000 Binary files a/views/images/settings/gcm-12.jpg and /dev/null differ diff --git a/views/images/settings/gcm-2.jpg b/views/images/settings/gcm-2.jpg index 2349ddf..1049195 100644 Binary files a/views/images/settings/gcm-2.jpg and b/views/images/settings/gcm-2.jpg differ diff --git a/views/images/settings/gcm-3.jpg b/views/images/settings/gcm-3.jpg index 7f5eeb8..81f09f4 100644 Binary files a/views/images/settings/gcm-3.jpg and b/views/images/settings/gcm-3.jpg differ diff --git a/views/images/settings/gcm-4.jpg b/views/images/settings/gcm-4.jpg index b654b2c..5e54eaa 100644 Binary files a/views/images/settings/gcm-4.jpg and b/views/images/settings/gcm-4.jpg differ diff --git a/views/images/settings/gcm-5.jpg b/views/images/settings/gcm-5.jpg index 2f7630e..63f75f0 100644 Binary files a/views/images/settings/gcm-5.jpg and b/views/images/settings/gcm-5.jpg differ diff --git a/views/images/settings/gcm-6.jpg b/views/images/settings/gcm-6.jpg index c6c75b1..82cd255 100644 Binary files a/views/images/settings/gcm-6.jpg and b/views/images/settings/gcm-6.jpg differ diff --git a/views/images/settings/gcm-7.jpg b/views/images/settings/gcm-7.jpg index 617ff1c..eba36f6 100644 Binary files a/views/images/settings/gcm-7.jpg and b/views/images/settings/gcm-7.jpg differ diff --git a/views/images/settings/gcm-8.jpg b/views/images/settings/gcm-8.jpg index 94e1af7..211d4a7 100644 Binary files a/views/images/settings/gcm-8.jpg and b/views/images/settings/gcm-8.jpg differ diff --git a/views/images/settings/gcm-9.jpg b/views/images/settings/gcm-9.jpg index 903783c..cb14297 100644 Binary files a/views/images/settings/gcm-9.jpg and b/views/images/settings/gcm-9.jpg differ