reviewscouk_reviews - Version 0.6.1

Version Notes

BugFix for Rich Snippet - Wasn't Displaying on Themes

Download this release

Release Info

Developer Reviews.co.uk
Extension reviewscouk_reviews
Version 0.6.1
Comparing to
See all releases


Code changes from version 0.6.0 to 0.6.1

app/design/frontend/base/default/layout/reviews_layout.xml CHANGED
@@ -8,8 +8,8 @@
8
  </reference>
9
  </catalog_product_view>
10
  <default>
11
- <reference name="footer">
12
- <block type="core/template" name="unique_name_here" template="reviews/rich_snippet.phtml" />
13
  </reference>
14
  </default>
15
  </layout>
8
  </reference>
9
  </catalog_product_view>
10
  <default>
11
+ <reference name="before_body_end">
12
+ <block type="core/template" name="reviews_rich_snippet" template="reviews/rich_snippet.phtml" />
13
  </reference>
14
  </default>
15
  </layout>
app/design/frontend/base/default/template/reviews/product_reviews_widget.phtml CHANGED
@@ -1,42 +1,5 @@
1
  <?php
2
  $enabled = Mage::getStoreConfig('reviewscouk_reviews_settings/widget/product_widget_enabled', Mage::app()->getStore());
3
- $colour = Mage::getStoreConfig('reviewscouk_reviews_settings/widget/product_widget_colour', Mage::app()->getStore());
4
- $store_id = Mage::getStoreConfig('reviewscouk_reviews_settings/api/reviews_store_id', Mage::app()->getStore());
5
- $region = Mage::getStoreConfig('reviewscouk_reviews_settings/api/reviews_region', Mage::app()->getStore());
6
-
7
- $productSkus = array();
8
- if(Mage::registry('current_product'))
9
- {
10
- $productSkus = Mage::helper('reviewshelper')->getProductSkus(Mage::registry('current_product'));
11
  }
12
-
13
- $api_url = 'widget.reviews.co.uk';
14
- if ($region == 'US') $api_url = 'widget.review.io';
15
-
16
- // people will sometimes put hash and sometimes they will forgot so we need to check for this error
17
- if(strpos($colour,'#') === FALSE) $colour = '#'.$colour;
18
-
19
- // checking to see if we hare a valid colour. If not then we change it to reviews default hex colour
20
- if(!preg_match('/^#[a-f0-9]{6}$/i', $colour)) $colour = '#5db11f';
21
- ?>
22
-
23
- <!-- Only Display this if enabled -->
24
- <?php if ($enabled): ?>
25
- <script src="https://<?php echo $api_url ?>/product/dist.js"></script>
26
- <div id="widget"></div>
27
- <script type="text/javascript">
28
- productWidget("widget", {
29
- store: '<?php echo $store_id; ?>',
30
- sku: '<?php echo implode(';',$productSkus); ?>', // Multiple SKU"s Seperated by Semi-Colons
31
- primaryClr: "<?php echo $colour; ?>",
32
- neutralClr: "#EBEBEB",
33
- buttonClr: "#EEE",
34
- textClr: "#333",
35
- tabClr: "#eee",
36
- questions: true,
37
- showTabs: true,
38
- ratingStars: false,
39
- showAvatars: true
40
- });
41
- </script>
42
- <?php endif; ?>
1
  <?php
2
  $enabled = Mage::getStoreConfig('reviewscouk_reviews_settings/widget/product_widget_enabled', Mage::app()->getStore());
3
+ if ($enabled){
4
+ echo Mage::helper('reviewshelper')->getProductWidget();
 
 
 
 
 
 
5
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
app/design/frontend/base/default/template/reviews/rich_snippet.phtml CHANGED
@@ -1,16 +1,7 @@
 
1
  <?php
2
  $enabled = Mage::getStoreConfig('reviewscouk_reviews_settings/rich_snippet/rich_snippet_enabled', Mage::app()->getStore());
3
-
4
- $sku = '';
5
- if(Mage::registry('current_product'))
6
- {
7
- $sku = Mage::helper('reviewshelper')->getProductSkus(Mage::registry('current_product'));
8
- }
9
- ?>
10
-
11
- <?php
12
  if($enabled){
13
- echo Mage::helper('reviewshelper')->getRichSnippet($sku);
14
  }
15
  ?>
16
-
1
+ <!-- Rich Snippet -->
2
  <?php
3
  $enabled = Mage::getStoreConfig('reviewscouk_reviews_settings/rich_snippet/rich_snippet_enabled', Mage::app()->getStore());
 
 
 
 
 
 
 
 
 
4
  if($enabled){
5
+ echo Mage::helper('reviewshelper')->autoRichSnippet();
6
  }
7
  ?>
 
package.xml CHANGED
@@ -1,18 +1,18 @@
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>reviewscouk_reviews</name>
4
- <version>0.6.0</version>
5
  <stability>stable</stability>
6
  <license>GPL</license>
7
  <channel>community</channel>
8
  <extends/>
9
  <summary>Reviews.co.uk Integration Plugin</summary>
10
  <description>Reviews.co.uk Integration Plugin</description>
11
- <notes>Review Booster Export Feature</notes>
12
  <authors><author><name>Reviews.co.uk</name><user>Reviews</user><email>support@reviews.co.uk</email></author></authors>
13
- <date>2016-01-14</date>
14
- <time>12:29:31</time>
15
- <contents><target name="magecommunity"><dir name="Reviewscouk"><dir name="Reviews"><dir name="Adminhtml"><dir name="Model"><dir name="System"><dir name="Config"><dir name="Source"><file name="Region.php" hash="65d7d2f061114099282e40a5353dc6a9"/></dir></dir></dir></dir></dir><dir name="Helper"><file name="Data.php" hash="51e852d3f4cfce17c04cde8a43f6f59a"/></dir><dir name="Model"><file name="Observer.php" hash="6d03f143367bf29478a79e5fd3987e85"/></dir><dir name="controllers"><dir name="Adminhtml"><file name="ReviewsController.php" hash="c39e013894681ece3d886041637cc1da"/></dir><file name="IndexController.php" hash="d6512ab7645eab3c191763ee217bfc61"/></dir><dir name="etc"><file name="adminhtml.xml" hash="1ef6673386095b6c8a7a7aefb654951b"/><file name="config.xml" hash="4433c04293b6ee55f74e086c978aa71b"/><file name="system.xml" hash="6015068dcb4ff36c25eddde0c8b79da0"/></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Reviewscouk_Reviews.xml" hash="347761ff6c475622697073d62f52e014"/></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="template"><dir name="reviews"><file name="dashboard.phtml" hash="925eeb5ee6bee1c7bf973f60008c1f3f"/><file name="export.phtml" hash="ab1225207cd4631941735c9a99594b65"/></dir></dir><dir name="layout"><file name="reviews_admin.xml" hash="3cdd4facfeb240634d81843cae1a5325"/></dir></dir></dir></dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="reviews_layout.xml" hash="ade6f7c127b8bca792bbfd75540f4673"/></dir><dir name="template"><dir name="reviews"><file name="product_reviews_widget.phtml" hash="07463b05d3542ea9b86bd48cb2765a7f"/><file name="rich_snippet.phtml" hash="a025c0fb68e737aae8bf0c09b55946a0"/><file name=".DS_Store" hash="4fe84b7db7aa067d7fd4b3ee082e4b2f"/></dir></dir></dir></dir></dir></target></contents>
16
  <compatible/>
17
  <dependencies><required><php><min>5.0.0</min><max>6.0.0</max></php></required></dependencies>
18
  </package>
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>reviewscouk_reviews</name>
4
+ <version>0.6.1</version>
5
  <stability>stable</stability>
6
  <license>GPL</license>
7
  <channel>community</channel>
8
  <extends/>
9
  <summary>Reviews.co.uk Integration Plugin</summary>
10
  <description>Reviews.co.uk Integration Plugin</description>
11
+ <notes>BugFix for Rich Snippet - Wasn't Displaying on Themes</notes>
12
  <authors><author><name>Reviews.co.uk</name><user>Reviews</user><email>support@reviews.co.uk</email></author></authors>
13
+ <date>2016-02-04</date>
14
+ <time>16:16:30</time>
15
+ <contents><target name="magecommunity"><dir name="Reviewscouk"><dir name="Reviews"><dir name="Adminhtml"><dir name="Model"><dir name="System"><dir name="Config"><dir name="Source"><file name="Region.php" hash="65d7d2f061114099282e40a5353dc6a9"/></dir></dir></dir></dir></dir><dir name="Helper"><file name="Data.php" hash="8ce25e8877bd7a28ca2d91fd1078cc62"/></dir><dir name="Model"><file name="Observer.php" hash="6d03f143367bf29478a79e5fd3987e85"/></dir><dir name="controllers"><dir name="Adminhtml"><file name="ReviewsController.php" hash="c39e013894681ece3d886041637cc1da"/></dir><file name="IndexController.php" hash="d6512ab7645eab3c191763ee217bfc61"/></dir><dir name="etc"><file name="adminhtml.xml" hash="1ef6673386095b6c8a7a7aefb654951b"/><file name="config.xml" hash="4433c04293b6ee55f74e086c978aa71b"/><file name="system.xml" hash="6015068dcb4ff36c25eddde0c8b79da0"/></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Reviewscouk_Reviews.xml" hash="347761ff6c475622697073d62f52e014"/></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="template"><dir name="reviews"><file name="dashboard.phtml" hash="925eeb5ee6bee1c7bf973f60008c1f3f"/><file name="export.phtml" hash="ab1225207cd4631941735c9a99594b65"/></dir></dir><dir name="layout"><file name="reviews_admin.xml" hash="3cdd4facfeb240634d81843cae1a5325"/></dir></dir></dir></dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="reviews_layout.xml" hash="18e2f32bc7d75d10645f7eb1730e43b3"/></dir><dir name="template"><dir name="reviews"><file name="product_reviews_widget.phtml" hash="3847d66e58638813eb3391c1fc49a683"/><file name="rich_snippet.phtml" hash="6868653c85b9ac76846db739fbe02b66"/><file name=".DS_Store" hash="4fe84b7db7aa067d7fd4b3ee082e4b2f"/></dir></dir></dir></dir></dir></target></contents>
16
  <compatible/>
17
  <dependencies><required><php><min>5.0.0</min><max>6.0.0</max></php></required></dependencies>
18
  </package>