From 480e41324dc46e0a64f0a9848d3522ec6f1c2806 Mon Sep 17 00:00:00 2001 From: Drew McDonald Date: Mon, 24 Feb 2020 09:27:49 -0600 Subject: [PATCH] 2.2.0 --- readme.txt | 82 +++++++++++++++++++------------------- secondstreet-promotion.php | 11 +++-- 2 files changed, 49 insertions(+), 44 deletions(-) diff --git a/readme.txt b/readme.txt index 03a085f..acc986a 100644 --- a/readme.txt +++ b/readme.txt @@ -1,41 +1,41 @@ -=== Add Script To Post === -Contributors: Second Street (Heather McCarron) -Tags: Page, Post, Shortcode, Promotion, Second Street, UPICKEM -Requires at least: 3.0 -Tested up to: 3.9.2 -Stable tag: trunk -License: GPLv2 or later -License URI: http://www.gnu.org/licenses/gpl-2.0.html - -Embed your Second Street Promotion on a WordPress page using the Shortcode generated in the Second Street Partner Tool. - - -== Description == - -The Second Street Promotion Plugin will allow you to embed your Second Street Promotion within your WordPress site. The feature to generate the Shortcode required for this plugin is located within your promotion's [Second Street Partner Tool](https://affiliates.upickem.net). After retrieving your Promotion's Shortcode, you will paste it into the page content area of the WordPress page you would like it to appear on. - -NOTE: The embedded Promotion's width will be dependent on the size of the parent container/element that it is placed in. If your promotion appears too narrow or too wide, try adjusting the width of its container. - - -== Installation == - -1. Extract files from the ZIP file. -2. Upload `secondstreet-promotion` folder (contains `secondstreet-promotion.php`) - to the `/wp-content/plugins/` directory. -3. Activate the plugin through the 'Plugins' menu in WordPress. -4. Retrieve (copy) your Promotion's Shortcode from your Second Street Partner Tool. - (Login to your Second Street account at https://affiliates.upickem.net) -5. Place (paste) your Shortcode into the page content area in your WordPress site. - - -== Frequently Asked Questions == - -= I cannot activate the Second Street Plugin. What should I do? = - -If you are having problems activating your plugin, please contact Second Street's [Support Department](http://affiliatesupport@secondstreet.com) to ask for help. - - -== Changelog == - -= 2.1.0 = -* Support for ss-promo, ss-signup, and ss-contest shortcodes +=== Second Street === +Contributors: Second Street +Tags: Page, Post, Shortcode, Promotion, Second Street, UPICKEM +Requires at least: 3.0 +Tested up to: 4.7 +Stable tag: trunk +License: GPLv2 or later +License URI: http://www.gnu.org/licenses/gpl-2.0.html + +Embed your Second Street Promotion on a WordPress page using the Shortcode generated in the Second Street Partner Tool. + + +== Description == + +The Second Street Plugin allows you to embed your Second Street content on your WordPress site. Get the Shortcode the specific Contest, Interactive Content, or Signup Widget you would like to embed from the Second Street app at [partners.secondstreet.com](https://partners.secondstreet.com). After retrieving your Shortcode, paste it into the page content area of the WordPress page you would like it to appear on. + +== Installation == + +1. Extract files from the ZIP file. +2. Upload `secondstreet-promotion` folder (contains `secondstreet-promotion.php`) + to the `/wp-content/plugins/` directory. +3. Activate the plugin through the 'Plugins' menu in WordPress. +4. Retrieve (copy) your Promotion's Shortcode from your Second Street Partner Tool. + (Login to your Second Street account at https://partners.secondstreet.com/) +5. Place (paste) your Shortcode into the page content area in your WordPress site. + + +== Frequently Asked Questions == + += I cannot activate the Second Street Plugin. What should I do? = + +If you are having problems activating your plugin, please contact Second Street's [Support Department](http://affiliatesupport@secondstreet.com) to ask for help. + + +== Changelog == + += 2.1.0 = +* Support for ss-promo, ss-signup, and ss-contest shortcodes + += 2.2.0 = +* Support for contest_id attribute for ss-contest shortcode diff --git a/secondstreet-promotion.php b/secondstreet-promotion.php index f90e77f..c4f805e 100644 --- a/secondstreet-promotion.php +++ b/secondstreet-promotion.php @@ -1,7 +1,7 @@ '', 'contest_folder' => '', - 'routing' => '' + 'routing' => '', + 'contest_id' => '' ), $atts ); $ss_script_url = $a['contest_url'] . '/' . 'shared/embedcode/embed.js'; - return ''; + if (esc_attr( $a['contest_id'] ) != '') { //Old Engine contests will pass contest_id + return ''; + } else { + return ''; + } }