Optimiseweb_Redirects - Version 0.2.0

Version Notes

* A fresh new version with many new features.
* Includes a disabled products redirect option

Download this release

Release Info

Developer Kathir Vel
Extension Optimiseweb_Redirects
Version 0.2.0
Comparing to
See all releases


Code changes from version 0.1.9 to 0.2.0

app/code/community/Optimiseweb/Redirects/Block/Adminhtml/System/Config/Fieldset/Hint.php ADDED
@@ -0,0 +1,89 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * Optimiseweb Redirects Block Adminhtml System Config Fieldset Hint
5
+ *
6
+ * @package Optimiseweb_Redirects
7
+ * @author Kathir Vel (sid@optimiseweb.co.uk)
8
+ * @copyright Copyright (c) 2014 Optimise Web
9
+ * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
10
+ */
11
+ class Optimiseweb_Redirects_Block_Adminhtml_System_Config_Fieldset_Hint extends Mage_Adminhtml_Block_Abstract implements Varien_Data_Form_Element_Renderer_Interface
12
+ {
13
+
14
+ protected $_template = 'optimiseweb/redirects/system/config/fieldset/hint.phtml';
15
+
16
+ /**
17
+ * Render fieldset html
18
+ *
19
+ * @param Varien_Data_Form_Element_Abstract $element
20
+ * @return string
21
+ */
22
+ public function render(Varien_Data_Form_Element_Abstract $element)
23
+ {
24
+ return $this->toHtml();
25
+ }
26
+
27
+ public function getModuleVersion()
28
+ {
29
+ return (string) Mage::getConfig()->getNode('modules/Optimiseweb_Redirects/version');
30
+ }
31
+
32
+ public function getOptimisewebRedirectsVersion()
33
+ {
34
+ return $this->getModuleVersion();
35
+ }
36
+
37
+ public function getCheckExtensions()
38
+ {
39
+ return array();
40
+ }
41
+
42
+ private function getAdminEmail()
43
+ {
44
+ return Mage::getSingleton('admin/session')->getUser()->getEmail();
45
+ }
46
+
47
+ public function getOptimiseWebUrl()
48
+ {
49
+ $url = '//optimiseweb.co.uk?';
50
+ $url .= 'utm_source=Magento_Extension&utm_medium=Extension_Settings&utm_campaign=Optimiseweb_Redirects';
51
+ return $url;
52
+ }
53
+
54
+ public function getOptimiseWebEmailLink()
55
+ {
56
+ $email = 'info@optimiseweb.co.uk';
57
+ $emailLink = 'mailto:' . $email;
58
+ return $emailLink;
59
+ }
60
+
61
+ public function getKathirVelUrl()
62
+ {
63
+ $url = '//www.kathirvel.com?';
64
+ $url .= 'utm_source=Magento_Extension&utm_medium=Extension_Settings&utm_campaign=Optimiseweb_Redirects';
65
+ return $url;
66
+ }
67
+
68
+ public function getHelpDeskUrl()
69
+ {
70
+ $url = '//optimiseweb.co.uk/magento-extension-support/?';
71
+ $url .= $this->getPxParams();
72
+ return $url;
73
+ }
74
+
75
+ public function getPxParams()
76
+ {
77
+ $v = $this->getModuleVersion();
78
+ $ext = 'Optimiseweb_Redirects_' . $v;
79
+ $modulesArray = (array) Mage::getConfig()->getNode('modules')->children();
80
+ $aux = (array_key_exists('Enterprise_Enterprise', $modulesArray)) ? 'EE' : 'CE';
81
+ $mageVersion = Mage::getVersion();
82
+ $mage = 'Magento_' . $aux . '_' . $mageVersion;
83
+ $hash = md5($ext . '_' . $mage . '_' . $ext);
84
+ $url = Mage::getBaseUrl();
85
+ $email = $this->getAdminEmail();
86
+ return 'extension=' . $ext . '&magento=' . $mage . '&url=' . $url . '&email=' . $email . '&ctrl=' . $hash;
87
+ }
88
+
89
+ }
app/code/community/Optimiseweb/Redirects/Model/Redirector.php CHANGED
@@ -14,24 +14,52 @@ class Optimiseweb_Redirects_Model_Redirector
14
  /**
15
  * Redirect Function
16
  *
17
- * Looks at 404 pages and then loads up the csv file to see if a match exists
18
  *
19
  * @param Varien_Event_Observer $observer
20
  */
21
  public function doRedirects(Varien_Event_Observer $observer)
22
  {
23
  $request = $observer->getEvent()->getControllerAction()->getRequest();
 
24
  $actionName = $request->getActionName();
 
 
 
25
  $requestUrl = rtrim($request->getScheme() . '://' . $request->getHttpHost() . $request->getRequestUri(), '/');
 
 
 
26
 
27
- if ($actionName == 'noRoute') {
 
28
  $this->doRedirectsLegacy($requestUrl);
 
29
  $this->doRedirects1($requestUrl);
 
30
  $this->doQueryStringRedirects($requestUrl);
 
 
31
  }
32
  return;
33
  }
34
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
35
  protected function doRedirectsLegacy($requestUrl)
36
  {
37
  if (Mage::getStoreConfig('optimisewebredirects/general/upload') AND file_exists(Mage::getBaseDir('media') . '/optimiseweb/redirects/' . Mage::getStoreConfig('optimisewebredirects/general/upload'))) {
@@ -133,7 +161,7 @@ class Optimiseweb_Redirects_Model_Redirector
133
  }
134
  }
135
  if ($doRedirect) {
136
- if (array_key_exists($queryVar, $queryParts) AND ($queryParts[$queryVar] == $queryValue)) {
137
  $response = Mage::app()->getResponse();
138
  $response->setRedirect($destinationUrl, $redirectCode);
139
  $response->sendResponse();
@@ -147,4 +175,30 @@ class Optimiseweb_Redirects_Model_Redirector
147
  }
148
  }
149
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
150
  }
14
  /**
15
  * Redirect Function
16
  *
17
+ * Looks at noRoute action and then loads up the csv files to see if a match exists
18
  *
19
  * @param Varien_Event_Observer $observer
20
  */
21
  public function doRedirects(Varien_Event_Observer $observer)
22
  {
23
  $request = $observer->getEvent()->getControllerAction()->getRequest();
24
+
25
  $actionName = $request->getActionName();
26
+
27
+ $disabledProductCheck = $this->disabledProductCheck($request);
28
+
29
  $requestUrl = rtrim($request->getScheme() . '://' . $request->getHttpHost() . $request->getRequestUri(), '/');
30
+ if ($disabledProductCheck) {
31
+ $requestUrl = rtrim($request->getScheme() . '://' . $request->getHttpHost() . '/' . $disabledProductCheck, '/');
32
+ }
33
 
34
+ if (($actionName == 'noRoute') OR $disabledProductCheck) {
35
+ Mage::dispatchEvent('optimiseweb_redirects_before_legacy', array('request_url' => &$requestUrl));
36
  $this->doRedirectsLegacy($requestUrl);
37
+ Mage::dispatchEvent('optimiseweb_redirects_before_v1', array('request_url' => &$requestUrl));
38
  $this->doRedirects1($requestUrl);
39
+ Mage::dispatchEvent('optimiseweb_redirects_before_query_strings', array('request_url' => &$requestUrl));
40
  $this->doQueryStringRedirects($requestUrl);
41
+ Mage::dispatchEvent('optimiseweb_redirects_before_catalogue_search', array('request_url' => &$requestUrl));
42
+ $this->doRedirectsToCatalogueSearch($requestUrl);
43
  }
44
  return;
45
  }
46
 
47
+ protected function disabledProductCheck($request)
48
+ {
49
+ if ($request->getActionName() !== 'noRoute') {
50
+ if (Mage::getStoreConfig('optimisewebredirects/disabled_products/enabled')) {
51
+ if (($request->getModuleName() == 'catalog') AND ( $request->getControllerName() == 'product') AND ( $request->getActionName() == 'view')) {
52
+ if ($product = Mage::getModel('catalog/product')->load(Mage::app()->getRequest()->getParam('id'))) {
53
+ if ($product->getStatus() == 2) {
54
+ return $product->getUrlPath();
55
+ }
56
+ }
57
+ }
58
+ }
59
+ }
60
+ return FALSE;
61
+ }
62
+
63
  protected function doRedirectsLegacy($requestUrl)
64
  {
65
  if (Mage::getStoreConfig('optimisewebredirects/general/upload') AND file_exists(Mage::getBaseDir('media') . '/optimiseweb/redirects/' . Mage::getStoreConfig('optimisewebredirects/general/upload'))) {
161
  }
162
  }
163
  if ($doRedirect) {
164
+ if (array_key_exists($queryVar, $queryParts) AND ( $queryParts[$queryVar] == $queryValue)) {
165
  $response = Mage::app()->getResponse();
166
  $response->setRedirect($destinationUrl, $redirectCode);
167
  $response->sendResponse();
175
  }
176
  }
177
 
178
+ protected function doRedirectsToCatalogueSearch($requestUrl)
179
+ {
180
+ if ((bool) Mage::getStoreConfig('optimisewebredirects/cataloguesearch/enabled')) {
181
+
182
+ $query = parse_url($requestUrl);
183
+ $queryUrl = $query['scheme'] . '://' . $query['host'] . $query['path'];
184
+ $requestUrlSlashTrimmed = rtrim($queryUrl, '/');
185
+ $queryPath = $query['path'];
186
+ $queryPathSlashTrimmed = ltrim($queryPath, '/');
187
+ $queryPathExploded = explode('/', $queryPathSlashTrimmed);
188
+ $queryPathLast = end($queryPathExploded);
189
+
190
+ $searchQueryString = str_replace('.html', '', $queryPathSlashTrimmed);
191
+ $searchQueryString = str_replace('/', '+', $searchQueryString);
192
+
193
+ $catalogueSearchUrl = Mage::helper('catalogsearch')->getResultUrl();
194
+ $catalogueSearchQueryUrl = $catalogueSearchUrl . '?q=' . $searchQueryString;
195
+
196
+ $response = Mage::app()->getResponse();
197
+ $response->setRedirect($catalogueSearchQueryUrl, 301);
198
+ $response->sendResponse();
199
+
200
+ exit;
201
+ }
202
+ }
203
+
204
  }
app/code/community/Optimiseweb/Redirects/etc/adminhtml.xml CHANGED
@@ -8,6 +8,27 @@
8
  */
9
  -->
10
  <config>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
11
  <acl>
12
  <resources>
13
  <all>
@@ -43,4 +64,5 @@
43
  </admin>
44
  </resources>
45
  </acl>
 
46
  </config>
8
  */
9
  -->
10
  <config>
11
+
12
+ <menu>
13
+ <optimiseweball translate="title" module="ow_redirects">
14
+ <title>Optimise Web</title>
15
+ <sort_order>71</sort_order>
16
+ <children>
17
+ <ow_redirects translate="title" module="ow_redirects">
18
+ <title>Mass 301 Redirects</title>
19
+ <sort_order>5</sort_order>
20
+ <action>adminhtml/system_config/edit/section/optimisewebredirects</action>
21
+ <depends>
22
+ <config>optimisewebredirects/menu/ow_redirects_enabled</config>
23
+ </depends>
24
+ </ow_redirects>
25
+ </children>
26
+ <depends>
27
+ <config>optimisewebredirects/menu/optimiseweball_enabled</config>
28
+ </depends>
29
+ </optimiseweball>
30
+ </menu>
31
+
32
  <acl>
33
  <resources>
34
  <all>
64
  </admin>
65
  </resources>
66
  </acl>
67
+
68
  </config>
app/code/community/Optimiseweb/Redirects/etc/config.xml CHANGED
@@ -11,7 +11,7 @@
11
 
12
  <modules>
13
  <Optimiseweb_Redirects>
14
- <version>0.1.9</version>
15
  </Optimiseweb_Redirects>
16
  </modules>
17
 
@@ -31,20 +31,6 @@
31
 
32
  <adminhtml>
33
 
34
- <menu>
35
- <optimiseweball translate="title" module="ow_redirects">
36
- <title>Optimise Web</title>
37
- <sort_order>71</sort_order>
38
- <children>
39
- <ow_redirects translate="title" module="ow_redirects">
40
- <title>Mass 301 Redirects</title>
41
- <sort_order>5</sort_order>
42
- <action>adminhtml/system_config/edit/section/optimisewebredirects</action>
43
- </ow_redirects>
44
- </children>
45
- </optimiseweball>
46
- </menu>
47
-
48
  <translate>
49
  <modules>
50
  <Optimiseweb_Redirects>
@@ -94,6 +80,9 @@
94
  <default>
95
 
96
  <optimisewebredirects>
 
 
 
97
  <redirects1>
98
  <delimiter>,</delimiter>
99
  <wildcardcharacter>*</wildcardcharacter>
@@ -102,6 +91,13 @@
102
  <delimiter>,</delimiter>
103
  <wildcardcharacter>*</wildcardcharacter>
104
  </querystring>
 
 
 
 
 
 
 
105
  </optimisewebredirects>
106
 
107
  </default>
11
 
12
  <modules>
13
  <Optimiseweb_Redirects>
14
+ <version>0.2.0</version>
15
  </Optimiseweb_Redirects>
16
  </modules>
17
 
31
 
32
  <adminhtml>
33
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
34
  <translate>
35
  <modules>
36
  <Optimiseweb_Redirects>
80
  <default>
81
 
82
  <optimisewebredirects>
83
+ <disabled_products>
84
+ <enabled>0</enabled>
85
+ </disabled_products>
86
  <redirects1>
87
  <delimiter>,</delimiter>
88
  <wildcardcharacter>*</wildcardcharacter>
91
  <delimiter>,</delimiter>
92
  <wildcardcharacter>*</wildcardcharacter>
93
  </querystring>
94
+ <cataloguesearch>
95
+ <enabled>0</enabled>
96
+ </cataloguesearch>
97
+ <menu>
98
+ <optimiseweball_enabled>1</optimiseweball_enabled>
99
+ <ow_redirects_enabled>1</ow_redirects_enabled>
100
+ </menu>
101
  </optimisewebredirects>
102
 
103
  </default>
app/code/community/Optimiseweb/Redirects/etc/system.xml CHANGED
@@ -26,9 +26,55 @@
26
  <show_in_website>1</show_in_website>
27
  <show_in_store>1</show_in_store>
28
  <groups>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
29
 
30
  <general translate="label comment" module="ow_redirects">
31
  <label>Legacy - Upload / Download CSV File</label>
 
 
 
 
 
 
 
 
 
 
32
  <frontend_type>text</frontend_type>
33
  <sort_order>2</sort_order>
34
  <show_in_default>1</show_in_default>
@@ -61,6 +107,18 @@
61
 
62
  <redirects1 translate="label comment" module="ow_redirects">
63
  <label>Redirects System v1.0</label>
 
 
 
 
 
 
 
 
 
 
 
 
64
  <frontend_type>text</frontend_type>
65
  <sort_order>3</sort_order>
66
  <show_in_default>1</show_in_default>
@@ -111,6 +169,18 @@
111
 
112
  <querystring translate="label comment" module="ow_redirects">
113
  <label>Query String Based Redirects</label>
 
 
 
 
 
 
 
 
 
 
 
 
114
  <frontend_type>text</frontend_type>
115
  <sort_order>4</sort_order>
116
  <show_in_default>1</show_in_default>
@@ -158,6 +228,72 @@
158
  </wildcardcharacter>
159
  </fields>
160
  </querystring>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
161
 
162
  </groups>
163
  </optimisewebredirects>
26
  <show_in_website>1</show_in_website>
27
  <show_in_store>1</show_in_store>
28
  <groups>
29
+
30
+ <hint>
31
+ <frontend_model>ow_redirects/adminhtml_system_config_fieldset_hint</frontend_model>
32
+ <sort_order>0</sort_order>
33
+ <show_in_default>1</show_in_default>
34
+ <show_in_website>1</show_in_website>
35
+ <show_in_store>1</show_in_store>
36
+ </hint>
37
+
38
+ <disabled_products translate="label comment" module="ow_redirects">
39
+ <label>Disabled Products Check</label>
40
+ <comment>
41
+ <![CDATA[
42
+ <div class="notice-msg" style="background-image: none!important; padding: 5px;">
43
+ <p>With this option set to 'Yes', you can prevent visitors of disabled products from going to a 404 page. This feature has now been added due to popular demand.</p>
44
+ <p style="margin-bottom: 0;">It is recommended to leave this option turned off unless you fully understand what the implications are. With this option set to 'Yes', this module will make a data call to check the product's status before every product page load. This could add a very tiny bit of additional processing before every product page load.</p>
45
+ </div>
46
+ ]]>
47
+ </comment>
48
+ <frontend_type>text</frontend_type>
49
+ <sort_order>1</sort_order>
50
+ <show_in_default>1</show_in_default>
51
+ <show_in_website>1</show_in_website>
52
+ <show_in_store>1</show_in_store>
53
+ <fields>
54
+ <enabled translate="label tooltip comment" module="ow_redirects">
55
+ <label>Redirect disabled products?</label>
56
+ <frontend_type>select</frontend_type>
57
+ <source_model>adminhtml/system_config_source_yesno</source_model>
58
+ <sort_order>1</sort_order>
59
+ <show_in_default>1</show_in_default>
60
+ <show_in_website>1</show_in_website>
61
+ <show_in_store>1</show_in_store>
62
+ </enabled>
63
+ </fields>
64
+ </disabled_products>
65
 
66
  <general translate="label comment" module="ow_redirects">
67
  <label>Legacy - Upload / Download CSV File</label>
68
+ <comment>
69
+ <![CDATA[
70
+ <div class="notice-msg" style="background-image: none!important; padding: 5px;">
71
+ <p>This option still works, but please consider using Redirects System v1.0 as it offers a better CSV format and supports redirect status codes.</p>
72
+ <p><strong>CSV Format (inside one single Excel cell):</strong></p>
73
+ <p>http://domain.com/old-path/;http://domain.com/new-path/</p>
74
+ <p style="margin-bottom: 0;">Please check the CSV file by opening it in a plain text editor. Formatting errors and additional carriage returns can cause the module to stop working.</p>
75
+ </div>
76
+ ]]>
77
+ </comment>
78
  <frontend_type>text</frontend_type>
79
  <sort_order>2</sort_order>
80
  <show_in_default>1</show_in_default>
107
 
108
  <redirects1 translate="label comment" module="ow_redirects">
109
  <label>Redirects System v1.0</label>
110
+ <comment>
111
+ <![CDATA[
112
+ <div class="notice-msg" style="background-image: none!important; padding: 5px;">
113
+ <p><strong>CSV Format (takes three Excel cells):</strong></p>
114
+ <p>http://domain.com/old-path/,http://domain.com/new-path/,301</p>
115
+ <p><strong>You can use wildcards!</strong></p>
116
+ <p>http://domain.com/old-*,http://domain.com/new-path/,301</p>
117
+ <p>The above example will redirect every 404 URL starting with http://domain.com/old- to http://domain.com/new-path/</p>
118
+ <p style="margin-bottom: 0;">To cater to different CSV formats, I have provided separator and wildcard customisation. Please check the CSV file by opening it in a plain text editor. Formatting errors and additional carriage returns can cause the module to stop working.</p>
119
+ </div>
120
+ ]]>
121
+ </comment>
122
  <frontend_type>text</frontend_type>
123
  <sort_order>3</sort_order>
124
  <show_in_default>1</show_in_default>
169
 
170
  <querystring translate="label comment" module="ow_redirects">
171
  <label>Query String Based Redirects</label>
172
+ <comment>
173
+ <![CDATA[
174
+ <div class="notice-msg" style="background-image: none!important; padding: 5px;">
175
+ <p><strong>CSV Format (takes five Excel cells):</strong></p>
176
+ <p>http://domain.com/old-base-path/,prod_id,101,http://domain.com/new-path/,301</p>
177
+ <p>The above example will match http://domain.com/old-base-path/?prod_id=101 and redirect the visitor to http://domain.com/new-path/ with a status code of 301.</p>
178
+ <p>The method uses a best match scenario. http://domain.com/old-base-path/?prod_id=101&cat_id=201 will match prod_id or cat_id, whichever comes first in the CSV.</p>
179
+ <p><strong>You can use wildcards!</strong></p>
180
+ <p>http://domain.com/old-*,prod_id,101,http://domain.com/new-path/,301</p>
181
+ </div>
182
+ ]]>
183
+ </comment>
184
  <frontend_type>text</frontend_type>
185
  <sort_order>4</sort_order>
186
  <show_in_default>1</show_in_default>
228
  </wildcardcharacter>
229
  </fields>
230
  </querystring>
231
+
232
+ <cataloguesearch translate="label comment" module="ow_redirects">
233
+ <label>Redirect to Catalogue Search (Experimental Feature)</label>
234
+ <comment>
235
+ <![CDATA[
236
+ <div class="notice-msg" style="background-image: none!important; padding: 5px;">
237
+ <p>Use this as a last resort option. Instead of landing on a 404 page, you can get the module to redirect your visitor to a search page.</p>
238
+ <p>Just a word of caution - enabling this option will make it so that there are no 404 errors on your website. This will even redirect missing images to a catalogue search.</p>
239
+ <p>At the moment, the search keyword will be triggered by breaking up the last URL path. e.g. /electronics/iphone-5s.html will trigger a search for "iphone 5s"</p>
240
+ <p style="margin-bottom: 0;">I hope to add more options and improve this feature in the future versions. Please send any suggestions that you might have.</p>
241
+ </div>
242
+ ]]>
243
+ </comment>
244
+ <frontend_type>text</frontend_type>
245
+ <sort_order>5</sort_order>
246
+ <show_in_default>1</show_in_default>
247
+ <show_in_website>1</show_in_website>
248
+ <show_in_store>1</show_in_store>
249
+ <fields>
250
+ <enabled translate="label tooltip comment" module="ow_redirects">
251
+ <label>Enable?</label>
252
+ <frontend_type>select</frontend_type>
253
+ <source_model>adminhtml/system_config_source_yesno</source_model>
254
+ <sort_order>1</sort_order>
255
+ <show_in_default>1</show_in_default>
256
+ <show_in_website>1</show_in_website>
257
+ <show_in_store>1</show_in_store>
258
+ </enabled>
259
+ </fields>
260
+ </cataloguesearch>
261
+
262
+ <menu translate="label comment" module="ow_redirects">
263
+ <label>Admin Menu Control</label>
264
+ <comment>
265
+ <![CDATA[
266
+ <div class="notice-msg" style="background-image: none!important; padding: 5px;">
267
+ <p style="margin-bottom: 0;">The 'Optimise Web' menu group acts as a parent menu item for the various modules developed by Optimise Web. If you do not wish to see the link in the admin menu and would rather manually visit the System Config.</p>
268
+ </div>
269
+ ]]>
270
+ </comment>
271
+ <frontend_type>text</frontend_type>
272
+ <sort_order>999</sort_order>
273
+ <show_in_default>1</show_in_default>
274
+ <show_in_website>1</show_in_website>
275
+ <show_in_store>1</show_in_store>
276
+ <fields>
277
+ <optimiseweball_enabled translate="label tooltip comment" module="ow_redirects">
278
+ <label>Enable the 'Optimise Web' Admin menu group?</label>
279
+ <frontend_type>select</frontend_type>
280
+ <source_model>adminhtml/system_config_source_yesno</source_model>
281
+ <sort_order>1</sort_order>
282
+ <show_in_default>1</show_in_default>
283
+ <show_in_website>1</show_in_website>
284
+ <show_in_store>1</show_in_store>
285
+ </optimiseweball_enabled>
286
+ <ow_redirects_enabled translate="label tooltip comment" module="ow_redirects">
287
+ <label>Enable the 'Mass 301 Redirects' link from the Admin menu?</label>
288
+ <frontend_type>select</frontend_type>
289
+ <source_model>adminhtml/system_config_source_yesno</source_model>
290
+ <sort_order>1</sort_order>
291
+ <show_in_default>1</show_in_default>
292
+ <show_in_website>1</show_in_website>
293
+ <show_in_store>1</show_in_store>
294
+ </ow_redirects_enabled>
295
+ </fields>
296
+ </menu>
297
 
298
  </groups>
299
  </optimisewebredirects>
app/design/adminhtml/default/default/template/optimiseweb/redirects/system/config/fieldset/hint.phtml ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <div class="optimiseweb-system-config-fieldset-hint">
2
+
3
+ <a target="_blank" href="<?php echo $this->getOptimiseWebUrl(); ?>"><img src="//optimiseweb.co.uk/magento-connect/assets/logo/optimiseweb.php?<?php echo $this->getPxParams(); ?>" /></a>
4
+
5
+ <h4>
6
+ <strong style="color:#ea7601;">Mass 301 Redirects v<?php echo $this->getModuleVersion(); ?></strong> by <a target="_blank" href="<?php echo $this->getOptimiseWebUrl(); ?>"><strong>Optimise Web</strong></a>
7
+ </h4>
8
+
9
+ <p>
10
+ <a target="_blank" href="<?php echo $this->getOptimiseWebUrl(); ?>"><strong>Optimise Web</strong></a> is a <strong>Full Service Digital Agency</strong> from Edinburgh (Scotland, UK).
11
+ The author of this extension, <a target="_blank" href="<?php echo $this->getKathirVelUrl(); ?>"><strong>Kathir 'Sid' Vel</strong></a>, is our eCommerce and Digital Marketing specialist.
12
+ </p>
13
+
14
+ <p>
15
+ Need assistance? <a target="_blank" href="<?php echo $this->getHelpDeskUrl(); ?>">Submit a ticket</a>.
16
+ Got feedback? <a target="_blank" href="<?php echo $this->getOptimiseWebEmailLink(); ?>">Email us</a>.
17
+ <!--Subscribe to our newsletter? <a target="_blank" href="<?php echo $this->getOptimiseWebUrl(); ?>">Visit our website</a>.-->
18
+ </p>
19
+
20
+ </div>
21
+
22
+ <style>
23
+ .optimiseweb-system-config-fieldset-hint {
24
+ background: #E7EFEF;
25
+ border: 1px solid #CCCCCC;
26
+ margin-bottom: 10px;
27
+ padding: 11px 0 0 10px;
28
+ }
29
+ </style>
package.xml CHANGED
@@ -1,7 +1,7 @@
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>Optimiseweb_Redirects</name>
4
- <version>0.1.9</version>
5
  <stability>stable</stability>
6
  <license uri="http://opensource.org/licenses/osl-3.0.php">Open Software License (OSL)</license>
7
  <channel>community</channel>
@@ -10,11 +10,12 @@
10
  <description>Magento has an internal URL Rewrite Management system. It can be a laborious task to add all your redirects, one by one.&#xD;
11
  &#xD;
12
  The Optimise Web Redirects extension allows you to upload all your redirect data as a CSV file.</description>
13
- <notes>Bug Fix - Parse Query was not being checked and creating log errors. Fixed it.</notes>
 
14
  <authors><author><name>Kathir Vel</name><user>OptimiseWeb</user><email>info@optimiseweb.co.uk</email></author></authors>
15
- <date>2014-02-03</date>
16
- <time>00:52:49</time>
17
- <contents><target name="magecommunity"><dir name="Optimiseweb"><dir name="Redirects"><dir name="Block"><dir name="System"><dir name="Config"><dir name="Backend"><file name="Download.php" hash="7aa495fa61b5dc8701ede38c4e00b343"/><file name="Download1.php" hash="83690ba4e42f356d92aecf3c5ef6d5d3"/><file name="Downloadquerystringfile.php" hash="51b51f70aa042bd09586fd03cfc55125"/></dir></dir></dir></dir><dir name="Helper"><file name="Data.php" hash="ca14b5ce332105a9a21a0bdc61200919"/></dir><dir name="Model"><file name="Redirector.php" hash="cf45f75d51fb3390ceee612d602ebbf5"/></dir><dir name="etc"><file name="adminhtml.xml" hash="f8c1b0efea4f1c17767bf3e5b7c58443"/><file name="config.xml" hash="f8474cd3fff9493b1cfdb54ade225ddd"/><file name="system.xml" hash="21d0a87a63e8651bc5c545d030039c0d"/></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Optimiseweb_Redirects.xml" hash="52171a52ca4993b6d25b51df3b762897"/></dir></target><target name="magelocale"><dir name="en_US"><file name="Optimiseweb_Redirects.csv" hash="d41d8cd98f00b204e9800998ecf8427e"/></dir></target></contents>
18
  <compatible/>
19
  <dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
20
  </package>
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>Optimiseweb_Redirects</name>
4
+ <version>0.2.0</version>
5
  <stability>stable</stability>
6
  <license uri="http://opensource.org/licenses/osl-3.0.php">Open Software License (OSL)</license>
7
  <channel>community</channel>
10
  <description>Magento has an internal URL Rewrite Management system. It can be a laborious task to add all your redirects, one by one.&#xD;
11
  &#xD;
12
  The Optimise Web Redirects extension allows you to upload all your redirect data as a CSV file.</description>
13
+ <notes>* A fresh new version with many new features.&#xD;
14
+ * Includes a disabled products redirect option</notes>
15
  <authors><author><name>Kathir Vel</name><user>OptimiseWeb</user><email>info@optimiseweb.co.uk</email></author></authors>
16
+ <date>2014-09-17</date>
17
+ <time>15:54:08</time>
18
+ <contents><target name="magecommunity"><dir name="Optimiseweb"><dir name="Redirects"><dir name="Block"><dir name="Adminhtml"><dir name="System"><dir name="Config"><dir name="Fieldset"><file name="Hint.php" hash="74a476f4b166ffe003a054b60d143306"/></dir></dir></dir></dir><dir name="System"><dir name="Config"><dir name="Backend"><file name="Download.php" hash="7aa495fa61b5dc8701ede38c4e00b343"/><file name="Download1.php" hash="83690ba4e42f356d92aecf3c5ef6d5d3"/><file name="Downloadquerystringfile.php" hash="51b51f70aa042bd09586fd03cfc55125"/></dir></dir></dir></dir><dir name="Helper"><file name="Data.php" hash="ca14b5ce332105a9a21a0bdc61200919"/></dir><dir name="Model"><file name="Redirector.php" hash="ecfc3142757c994e831999f3982d488b"/></dir><dir name="etc"><file name="adminhtml.xml" hash="dd58dc054f2933de6f68a1986c444ab5"/><file name="config.xml" hash="916251efbe4687cf4e39a0dc8d09a369"/><file name="system.xml" hash="d74393068cf94bdf27bc094eb5111201"/></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Optimiseweb_Redirects.xml" hash="52171a52ca4993b6d25b51df3b762897"/></dir></target><target name="magelocale"><dir name="en_US"><file name="Optimiseweb_Redirects.csv" hash="d41d8cd98f00b204e9800998ecf8427e"/></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="template"><dir name="optimiseweb"><dir name="redirects"><dir name="system"><dir name="config"><dir name="fieldset"><file name="hint.phtml" hash="0f9fd3a46bb90b37e345baad877cfec7"/></dir></dir></dir></dir></dir></dir></dir></dir></dir></target></contents>
19
  <compatible/>
20
  <dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
21
  </package>