Version Notes
to show free shipping message
Download this release
Release Info
| Developer | Navneet |
| Extension | SAG_Shippingmessage |
| Version | 1.0.0 |
| Comparing to | |
| See all releases | |
Version 1.0.0
- app/code/community/Sag/Shippingmessage/Block/message.php +62 -0
- app/code/community/Sag/Shippingmessage/Helper/Data.php +30 -0
- app/code/community/Sag/Shippingmessage/etc/config.xml +91 -0
- app/code/community/Sag/Shippingmessage/etc/system.xml +145 -0
- app/design/frontend/base/default/layout/shippingmessage.xml +52 -0
- app/design/frontend/base/default/template/shippingmessage/message.phtml +78 -0
- app/etc/modules/Sag_Shippingmessage.xml +35 -0
- package.xml +28 -0
app/code/community/Sag/Shippingmessage/Block/message.php
ADDED
|
@@ -0,0 +1,62 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* SAGIPL
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 11 |
+
*
|
| 12 |
+
* @category SAGIPL
|
| 13 |
+
* @package Sag_Shippingmessage
|
| 14 |
+
* @copyright Copyright (c) 2014 SAGIPL. (http://www.sagipl.com/)
|
| 15 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 16 |
+
*/
|
| 17 |
+
|
| 18 |
+
/**
|
| 19 |
+
* Free Shipping Message
|
| 20 |
+
*
|
| 21 |
+
* @category SAGIPL
|
| 22 |
+
* @package Sag_Shippingmessage
|
| 23 |
+
* @author Navneet <navneet.kshk@gmail.com>
|
| 24 |
+
*/
|
| 25 |
+
|
| 26 |
+
class Sag_Shippingmessage_Block_Message extends Mage_Core_Block_Template
|
| 27 |
+
{
|
| 28 |
+
public function _prepareLayout()
|
| 29 |
+
{
|
| 30 |
+
parent::_prepareLayout();
|
| 31 |
+
}
|
| 32 |
+
|
| 33 |
+
public function getShippinmessage(){
|
| 34 |
+
|
| 35 |
+
$_module_enabaled = Mage::getStoreConfig('sagshippingmessage/general/shippingmessage_enabled_select_box',Mage::app()->getStore());
|
| 36 |
+
|
| 37 |
+
if($_module_enabaled==1){
|
| 38 |
+
if(
|
| 39 |
+
Mage::getStoreConfig('sagshippingmessage/general/shippingmessage_value')!='' &&
|
| 40 |
+
Mage::getStoreConfig('sagshippingmessage/general/shippingmessage_congratulation')!='' &&
|
| 41 |
+
Mage::getStoreConfig('sagshippingmessage/general/shippingmessage_msg')
|
| 42 |
+
){
|
| 43 |
+
$configValue = Mage::getStoreConfig('sagshippingmessage/general/shippingmessage_value');
|
| 44 |
+
$subtot = Mage::helper('checkout/cart')->getQuote()->getSubtotal();
|
| 45 |
+
if($subtot!=0.0000){
|
| 46 |
+
if($subtot<$configValue){
|
| 47 |
+
$forfree = $configValue-$subtot;
|
| 48 |
+
return "Shopping more $".$forfree." for free shipping.";
|
| 49 |
+
}else{
|
| 50 |
+
return Mage::getStoreConfig('sagshippingmessage/general/shippingmessage_congratulation');
|
| 51 |
+
}
|
| 52 |
+
}else{
|
| 53 |
+
return Mage::getStoreConfig('sagshippingmessage/general/shippingmessage_msg');
|
| 54 |
+
}
|
| 55 |
+
}else{
|
| 56 |
+
return "Please fill all value for free shipping message extension";
|
| 57 |
+
}
|
| 58 |
+
}
|
| 59 |
+
|
| 60 |
+
}
|
| 61 |
+
|
| 62 |
+
}
|
app/code/community/Sag/Shippingmessage/Helper/Data.php
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* SAGIPL
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 11 |
+
*
|
| 12 |
+
* @category SAGIPL
|
| 13 |
+
* @package Sag_Shippingmessage
|
| 14 |
+
* @copyright Copyright (c) 2014 SAGIPL. (http://www.sagipl.com/)
|
| 15 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 16 |
+
*/
|
| 17 |
+
|
| 18 |
+
/**
|
| 19 |
+
* Free Shipping Message
|
| 20 |
+
*
|
| 21 |
+
* @category SAGIPL
|
| 22 |
+
* @package Sag_Shippingmessage
|
| 23 |
+
* @author Navneet <navneet.kshk@gmail.com>
|
| 24 |
+
*/
|
| 25 |
+
|
| 26 |
+
class Sag_Shippingmessage_Helper_Data extends Mage_Core_Helper_Abstract
|
| 27 |
+
{
|
| 28 |
+
|
| 29 |
+
}
|
| 30 |
+
?>
|
app/code/community/Sag/Shippingmessage/etc/config.xml
ADDED
|
@@ -0,0 +1,91 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<!--
|
| 3 |
+
/**
|
| 4 |
+
* SAGIPL
|
| 5 |
+
*
|
| 6 |
+
* NOTICE OF LICENSE
|
| 7 |
+
*
|
| 8 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 9 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 10 |
+
* It is also available through the world-wide-web at this URL:
|
| 11 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 12 |
+
*
|
| 13 |
+
* @category SAGIPL
|
| 14 |
+
* @package Sag_Shippingmessage
|
| 15 |
+
* @copyright Copyright (c) 2014 SAGIPL. (http://www.sagipl.com/)
|
| 16 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 17 |
+
*/
|
| 18 |
+
|
| 19 |
+
/**
|
| 20 |
+
* Free Shipping Message
|
| 21 |
+
*
|
| 22 |
+
* @category SAGIPL
|
| 23 |
+
* @package Sag_Shippingmessage
|
| 24 |
+
* @author Navneet <navneet.kshk@gmail.com>
|
| 25 |
+
*/
|
| 26 |
+
-->
|
| 27 |
+
|
| 28 |
+
<config>
|
| 29 |
+
<modules>
|
| 30 |
+
<Sag_Shippingmessage>
|
| 31 |
+
<version>1.0.0</version>
|
| 32 |
+
</Sag_Shippingmessage>
|
| 33 |
+
</modules>
|
| 34 |
+
<frontend>
|
| 35 |
+
<layout>
|
| 36 |
+
<updates>
|
| 37 |
+
<shippingmessage>
|
| 38 |
+
<file>shippingmessage.xml</file>
|
| 39 |
+
</shippingmessage>
|
| 40 |
+
</updates>
|
| 41 |
+
</layout>
|
| 42 |
+
</frontend>
|
| 43 |
+
<admin>
|
| 44 |
+
<routers>
|
| 45 |
+
<shippingmessage>
|
| 46 |
+
<use>admin</use>
|
| 47 |
+
<args>
|
| 48 |
+
<module>Sag_Shippingmessage</module>
|
| 49 |
+
<frontName>shippingmessage</frontName>
|
| 50 |
+
</args>
|
| 51 |
+
</shippingmessage>
|
| 52 |
+
</routers>
|
| 53 |
+
</admin>
|
| 54 |
+
<adminhtml>
|
| 55 |
+
<acl>
|
| 56 |
+
<resources>
|
| 57 |
+
<all>
|
| 58 |
+
<title>Allow Everything</title>
|
| 59 |
+
</all>
|
| 60 |
+
<admin>
|
| 61 |
+
<children>
|
| 62 |
+
<system>
|
| 63 |
+
<children>
|
| 64 |
+
<config>
|
| 65 |
+
<children>
|
| 66 |
+
<sagshippingmessage translate="title">
|
| 67 |
+
<title>Sag Free Shipping Message</title>
|
| 68 |
+
<sort_order>1</sort_order>
|
| 69 |
+
</sagshippingmessage>
|
| 70 |
+
</children>
|
| 71 |
+
</config>
|
| 72 |
+
</children>
|
| 73 |
+
</system>
|
| 74 |
+
</children>
|
| 75 |
+
</admin>
|
| 76 |
+
</resources>
|
| 77 |
+
</acl>
|
| 78 |
+
</adminhtml>
|
| 79 |
+
<global>
|
| 80 |
+
<blocks>
|
| 81 |
+
<shippingmessage>
|
| 82 |
+
<class>Sag_Shippingmessage_Block</class>
|
| 83 |
+
</shippingmessage>
|
| 84 |
+
</blocks>
|
| 85 |
+
<helpers>
|
| 86 |
+
<shippingmessage>
|
| 87 |
+
<class>Sag_Shippingmessage_Helper</class>
|
| 88 |
+
</shippingmessage>
|
| 89 |
+
</helpers>
|
| 90 |
+
</global>
|
| 91 |
+
</config>
|
app/code/community/Sag/Shippingmessage/etc/system.xml
ADDED
|
@@ -0,0 +1,145 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0" encoding="UTF-8"?>
|
| 2 |
+
<!--
|
| 3 |
+
/**
|
| 4 |
+
* SAGIPL
|
| 5 |
+
*
|
| 6 |
+
* NOTICE OF LICENSE
|
| 7 |
+
*
|
| 8 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 9 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 10 |
+
* It is also available through the world-wide-web at this URL:
|
| 11 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 12 |
+
*
|
| 13 |
+
* @category SAGIPL
|
| 14 |
+
* @package Sag_Shippingmessage
|
| 15 |
+
* @copyright Copyright (c) 2014 SAGIPL. (http://www.sagipl.com/)
|
| 16 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 17 |
+
*/
|
| 18 |
+
|
| 19 |
+
/**
|
| 20 |
+
* Free Shipping Message
|
| 21 |
+
*
|
| 22 |
+
* @category SAGIPL
|
| 23 |
+
* @package Sag_Shippingmessage
|
| 24 |
+
* @author Navneet <navneet.kshk@gmail.com>
|
| 25 |
+
*/
|
| 26 |
+
-->
|
| 27 |
+
|
| 28 |
+
<config>
|
| 29 |
+
<tabs>
|
| 30 |
+
<shippingmessage translate="label" module="shipping">
|
| 31 |
+
<label>SAG Free Shipping Message</label>
|
| 32 |
+
<sort_order>100</sort_order>
|
| 33 |
+
</shippingmessage>
|
| 34 |
+
</tabs>
|
| 35 |
+
<sections>
|
| 36 |
+
<sagshippingmessage translate="label" module="shippingmessage">
|
| 37 |
+
<label>Extension Options</label>
|
| 38 |
+
<tab>shippingmessage</tab>
|
| 39 |
+
<sort_order>1000</sort_order>
|
| 40 |
+
<show_in_default>1</show_in_default>
|
| 41 |
+
<show_in_website>1</show_in_website>
|
| 42 |
+
<show_in_store>1</show_in_store>
|
| 43 |
+
<groups>
|
| 44 |
+
<readme translate="label">
|
| 45 |
+
<label>Information about SAG infotech</label>
|
| 46 |
+
<frontend_type>text</frontend_type>
|
| 47 |
+
<sort_order>-1</sort_order>
|
| 48 |
+
<show_in_default>1</show_in_default>
|
| 49 |
+
<show_in_website>1</show_in_website>
|
| 50 |
+
<show_in_store>1</show_in_store>
|
| 51 |
+
<fields>
|
| 52 |
+
<information>
|
| 53 |
+
<label>About Company</label>
|
| 54 |
+
<comment>
|
| 55 |
+
<![CDATA[The Best Website Design, Web Application Development , web solutions Company backed by a team of creative and experienced web designers, web developers. Website: <a href="http://www.sagipl.com" target="_blank">sagipl.com</a> ]]>
|
| 56 |
+
</comment>
|
| 57 |
+
<frontend_type>label</frontend_type>
|
| 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 |
+
</information>
|
| 63 |
+
</fields>
|
| 64 |
+
</readme>
|
| 65 |
+
<general translate="label" module="shippingmessage">
|
| 66 |
+
<label>General Extension Options</label>
|
| 67 |
+
<frontend_type>text</frontend_type>
|
| 68 |
+
<sort_order>1000</sort_order>
|
| 69 |
+
<show_in_default>1</show_in_default>
|
| 70 |
+
<show_in_website>1</show_in_website>
|
| 71 |
+
<show_in_store>1</show_in_store>
|
| 72 |
+
<fields>
|
| 73 |
+
<shippingmessage_enabled_select_box translate="label">
|
| 74 |
+
<label>Enabled: </label>
|
| 75 |
+
<comment>Make extension enabled Yes/No</comment>
|
| 76 |
+
<frontend_type>select</frontend_type>
|
| 77 |
+
<sort_order>1</sort_order>
|
| 78 |
+
<show_in_default>1</show_in_default>
|
| 79 |
+
<show_in_website>1</show_in_website>
|
| 80 |
+
<show_in_store>1</show_in_store>
|
| 81 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
| 82 |
+
</shippingmessage_enabled_select_box>
|
| 83 |
+
<shippingmessage_showinheader_select_box translate="label">
|
| 84 |
+
<label>Show in Header: </label>
|
| 85 |
+
<comment>Show in header enabled Yes/No</comment>
|
| 86 |
+
<frontend_type>select</frontend_type>
|
| 87 |
+
<sort_order>2</sort_order>
|
| 88 |
+
<show_in_default>1</show_in_default>
|
| 89 |
+
<show_in_website>1</show_in_website>
|
| 90 |
+
<show_in_store>1</show_in_store>
|
| 91 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
| 92 |
+
</shippingmessage_showinheader_select_box>
|
| 93 |
+
<shippingmessage_showinleft_select_box translate="label">
|
| 94 |
+
<label>Show in Left: </label>
|
| 95 |
+
<comment>Show in left enabled Yes/No</comment>
|
| 96 |
+
<frontend_type>select</frontend_type>
|
| 97 |
+
<sort_order>3</sort_order>
|
| 98 |
+
<show_in_default>1</show_in_default>
|
| 99 |
+
<show_in_website>1</show_in_website>
|
| 100 |
+
<show_in_store>1</show_in_store>
|
| 101 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
| 102 |
+
</shippingmessage_showinleft_select_box>
|
| 103 |
+
<shippingmessage_showinright_select_box translate="label">
|
| 104 |
+
<label>Show in Right: </label>
|
| 105 |
+
<comment>Show in right enabled Yes/No</comment>
|
| 106 |
+
<frontend_type>select</frontend_type>
|
| 107 |
+
<sort_order>4</sort_order>
|
| 108 |
+
<show_in_default>1</show_in_default>
|
| 109 |
+
<show_in_website>1</show_in_website>
|
| 110 |
+
<show_in_store>1</show_in_store>
|
| 111 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
| 112 |
+
</shippingmessage_showinright_select_box>
|
| 113 |
+
<shippingmessage_value translate="label">
|
| 114 |
+
<label>Free Shipping Price: </label>
|
| 115 |
+
<comment>Enter price for free shipping.</comment>
|
| 116 |
+
<frontend_type>text</frontend_type>
|
| 117 |
+
<sort_order>5</sort_order>
|
| 118 |
+
<show_in_default>1</show_in_default>
|
| 119 |
+
<show_in_website>1</show_in_website>
|
| 120 |
+
<show_in_store>1</show_in_store>
|
| 121 |
+
</shippingmessage_value>
|
| 122 |
+
<shippingmessage_msg translate="label">
|
| 123 |
+
<label>Free Shipping Message: </label>
|
| 124 |
+
<comment>Enter message for free shipping.</comment>
|
| 125 |
+
<frontend_type>text</frontend_type>
|
| 126 |
+
<sort_order>6</sort_order>
|
| 127 |
+
<show_in_default>1</show_in_default>
|
| 128 |
+
<show_in_website>1</show_in_website>
|
| 129 |
+
<show_in_store>1</show_in_store>
|
| 130 |
+
</shippingmessage_msg>
|
| 131 |
+
<shippingmessage_congratulation translate="label">
|
| 132 |
+
<label>Free Shipping Congratulation Message: </label>
|
| 133 |
+
<comment>Enter message for Congratulation.</comment>
|
| 134 |
+
<frontend_type>text</frontend_type>
|
| 135 |
+
<sort_order>7</sort_order>
|
| 136 |
+
<show_in_default>1</show_in_default>
|
| 137 |
+
<show_in_website>1</show_in_website>
|
| 138 |
+
<show_in_store>1</show_in_store>
|
| 139 |
+
</shippingmessage_congratulation>
|
| 140 |
+
</fields>
|
| 141 |
+
</general>
|
| 142 |
+
</groups>
|
| 143 |
+
</sagshippingmessage>
|
| 144 |
+
</sections>
|
| 145 |
+
</config>
|
app/design/frontend/base/default/layout/shippingmessage.xml
ADDED
|
@@ -0,0 +1,52 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<!--
|
| 3 |
+
/**
|
| 4 |
+
* SAGIPL
|
| 5 |
+
*
|
| 6 |
+
* NOTICE OF LICENSE
|
| 7 |
+
*
|
| 8 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 9 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 10 |
+
* It is also available through the world-wide-web at this URL:
|
| 11 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 12 |
+
*
|
| 13 |
+
* @category SAGIPL
|
| 14 |
+
* @package Sag_Shippingmessage
|
| 15 |
+
* @copyright Copyright (c) 2014 SAGIPL. (http://www.sagipl.com/)
|
| 16 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 17 |
+
*/
|
| 18 |
+
|
| 19 |
+
/**
|
| 20 |
+
* Free Shipping Message
|
| 21 |
+
*
|
| 22 |
+
* @category SAGIPL
|
| 23 |
+
* @package Sag_Shippingmessage
|
| 24 |
+
* @author Navneet <navneet.kshk@gmail.com>
|
| 25 |
+
*/
|
| 26 |
+
-->
|
| 27 |
+
|
| 28 |
+
<layout version="0.1.0">
|
| 29 |
+
<default>
|
| 30 |
+
<reference name="top.container">
|
| 31 |
+
<block type="shippingmessage/message" name="message">
|
| 32 |
+
<action method="setTemplate" ifconfig="sagshippingmessage/general/shippingmessage_showinheader_select_box">
|
| 33 |
+
<template>shippingmessage/message.phtml</template>
|
| 34 |
+
</action>
|
| 35 |
+
</block>
|
| 36 |
+
</reference>
|
| 37 |
+
<reference name="left">
|
| 38 |
+
<block type="shippingmessage/message" name="message">
|
| 39 |
+
<action method="setTemplate" ifconfig="sagshippingmessage/general/shippingmessage_showinleft_select_box">
|
| 40 |
+
<template>shippingmessage/message.phtml</template>
|
| 41 |
+
</action>
|
| 42 |
+
</block>
|
| 43 |
+
</reference>
|
| 44 |
+
<reference name="right">
|
| 45 |
+
<block type="shippingmessage/message" name="message">
|
| 46 |
+
<action method="setTemplate" ifconfig="sagshippingmessage/general/shippingmessage_showinright_select_box">
|
| 47 |
+
<template>shippingmessage/message.phtml</template>
|
| 48 |
+
</action>
|
| 49 |
+
</block>
|
| 50 |
+
</reference>
|
| 51 |
+
</default>
|
| 52 |
+
</layout>
|
app/design/frontend/base/default/template/shippingmessage/message.phtml
ADDED
|
@@ -0,0 +1,78 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* SAGIPL
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 11 |
+
*
|
| 12 |
+
* @category SAGIPL
|
| 13 |
+
* @package Sag_Shippingmessage
|
| 14 |
+
* @copyright Copyright (c) 2014 SAGIPL. (http://www.sagipl.com/)
|
| 15 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 16 |
+
*/
|
| 17 |
+
|
| 18 |
+
/**
|
| 19 |
+
* Free Shipping Message
|
| 20 |
+
*
|
| 21 |
+
* @category SAGIPL
|
| 22 |
+
* @package Sag_Shippingmessage
|
| 23 |
+
* @author Navneet <navneet.kshk@gmail.com>
|
| 24 |
+
*/
|
| 25 |
+
|
| 26 |
+
$message = $this->getShippinmessage();
|
| 27 |
+
if($message!=''){
|
| 28 |
+
?>
|
| 29 |
+
|
| 30 |
+
<style>
|
| 31 |
+
.message{ border:2px solid #CC0;
|
| 32 |
+
border-radius:5px;
|
| 33 |
+
padding:5px;
|
| 34 |
+
background:#1f3241;
|
| 35 |
+
text-decoration: none;
|
| 36 |
+
font-weight:bold;
|
| 37 |
+
font-size:16px;
|
| 38 |
+
margin:5px;
|
| 39 |
+
display: block;
|
| 40 |
+
float:left;
|
| 41 |
+
-webkit-animation: spaceboots 2s linear infinite;
|
| 42 |
+
-moz-animation: spaceboots 2s linear infinite;
|
| 43 |
+
-ms-animation: spaceboots 2s linear infinite;
|
| 44 |
+
animation: spaceboots 2s linear infinite;
|
| 45 |
+
color:#f63c43;
|
| 46 |
+
}
|
| 47 |
+
|
| 48 |
+
@keyframes spaceboots {
|
| 49 |
+
0% { transform: translate(2px, 1px) rotate(0deg); }
|
| 50 |
+
10% { transform: translate(-1px, -2px) rotate(-1deg); }
|
| 51 |
+
20% { transform: translate(-3px, 0px) rotate(1deg); }
|
| 52 |
+
30% { transform: translate(0px, 2px) rotate(0deg); }
|
| 53 |
+
40% { transform: translate(1px, -1px) rotate(1deg); }
|
| 54 |
+
50% { transform: translate(-1px, 2px) rotate(-1deg); }
|
| 55 |
+
60% { transform: translate(-3px, 1px) rotate(0deg);}
|
| 56 |
+
70% { transform: translate(2px, 1px) rotate(-1deg); }
|
| 57 |
+
80% { transform: translate(-1px, -1px) rotate(1deg); }
|
| 58 |
+
90% { transform: translate(2px, 2px) rotate(0deg); }
|
| 59 |
+
100% { transform: translate(1px, -2px) rotate(-1deg); }
|
| 60 |
+
}
|
| 61 |
+
|
| 62 |
+
@-webkit-keyframes spaceboots {
|
| 63 |
+
0% { -webkit-transform: translate(2px, 1px) rotate(0deg); }
|
| 64 |
+
10% { -webkit-transform: translate(-1px, -2px) rotate(-1deg); }
|
| 65 |
+
20% { -webkit-transform: translate(-3px, 0px) rotate(1deg); }
|
| 66 |
+
30% { -webkit-transform: translate(0px, 2px) rotate(0deg); }
|
| 67 |
+
40% { -webkit-transform: translate(1px, -1px) rotate(1deg); }
|
| 68 |
+
50% { -webkit-transform: translate(-1px, 2px) rotate(-1deg); }
|
| 69 |
+
60% { -webkit-transform: translate(-3px, 1px) rotate(0deg);}
|
| 70 |
+
70% { -webkit-transform: translate(2px, 1px) rotate(-1deg); }
|
| 71 |
+
80% { -webkit-transform: translate(-1px, -1px) rotate(1deg); }
|
| 72 |
+
90% { -webkit-transform: translate(2px, 2px) rotate(0deg); }
|
| 73 |
+
100% { -webkit-transform: translate(1px, -2px) rotate(-1deg); }
|
| 74 |
+
}
|
| 75 |
+
</style>
|
| 76 |
+
|
| 77 |
+
<div class="message"><?php echo $message;?></div>
|
| 78 |
+
<?php } ?>
|
app/etc/modules/Sag_Shippingmessage.xml
ADDED
|
@@ -0,0 +1,35 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<!--
|
| 3 |
+
/**
|
| 4 |
+
* SAGIPL
|
| 5 |
+
*
|
| 6 |
+
* NOTICE OF LICENSE
|
| 7 |
+
*
|
| 8 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 9 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 10 |
+
* It is also available through the world-wide-web at this URL:
|
| 11 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 12 |
+
*
|
| 13 |
+
* @category SAGIPL
|
| 14 |
+
* @package Sag_Shippingmessage
|
| 15 |
+
* @copyright Copyright (c) 2014 SAGIPL. (http://www.sagipl.com/)
|
| 16 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 17 |
+
*/
|
| 18 |
+
|
| 19 |
+
/**
|
| 20 |
+
* Free Shipping Message
|
| 21 |
+
*
|
| 22 |
+
* @category SAGIPL
|
| 23 |
+
* @package Sag_Shippingmessage
|
| 24 |
+
* @author Navneet <navneet.kshk@gmail.com>
|
| 25 |
+
*/
|
| 26 |
+
-->
|
| 27 |
+
|
| 28 |
+
<config>
|
| 29 |
+
<modules>
|
| 30 |
+
<Sag_Shippingmessage>
|
| 31 |
+
<active>true</active>
|
| 32 |
+
<codePool>community</codePool>
|
| 33 |
+
</Sag_Shippingmessage>
|
| 34 |
+
</modules>
|
| 35 |
+
</config>
|
package.xml
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<package>
|
| 3 |
+
<name>SAG_Shippingmessage</name>
|
| 4 |
+
<version>1.0.0</version>
|
| 5 |
+
<stability>stable</stability>
|
| 6 |
+
<license>OSL v3.0</license>
|
| 7 |
+
<channel>community</channel>
|
| 8 |
+
<extends/>
|
| 9 |
+
<summary>to show free shipping message</summary>
|
| 10 |
+
<description><h3>Features:</h3>
|
| 11 |
+
<ul>
|
| 12 |
+
<li>Create a message to inform customers for free shipping. </li>
|
| 13 |
+
<li>Easy to install</li>
|
| 14 |
+
</ul>
|
| 15 |
+

|
| 16 |
+
<h3>Steps:</h3>
|
| 17 |
+
<ul>
|
| 18 |
+
<li>Install module , Clear cache and logout, login again. Check System->Configuration, in left side Go to “<b>SAG FREE SHIPPING MESSAGE</b>“,here manage extension options.</li>
|
| 19 |
+
<li>Front end: View Free Shipping Message in top header, left and right position which is enable in System->Configuration.</li>
|
| 20 |
+
</ul></description>
|
| 21 |
+
<notes>to show free shipping message</notes>
|
| 22 |
+
<authors><author><name>Navneet</name><user>navneetkoshik</user><email>navneet.kshk@gmail.com</email></author></authors>
|
| 23 |
+
<date>2015-01-06</date>
|
| 24 |
+
<time>10:57:53</time>
|
| 25 |
+
<contents><target name="magecommunity"><dir name="Sag"><dir name="Shippingmessage"><dir name="Block"><file name="message.php" hash="ac8bacf54ec236822de0fe941ea90ff2"/></dir><dir name="Helper"><file name="Data.php" hash="1ed866a45280f043c96022de3409737b"/></dir><dir name="etc"><file name="config.xml" hash="03e3811828e0fdbd9f3cca8712be1db5"/><file name="system.xml" hash="b526afc34ec9061e3afef2a8e93217a9"/></dir></dir></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="shippingmessage.xml" hash="8050d3c01d8f97447af1fd82f64979ae"/></dir><dir name="template"><dir name="shippingmessage"><file name="message.phtml" hash="f4d194b43fd1301957c6546ddd28f7c6"/></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Sag_Shippingmessage.xml" hash="d84f1fb31ae3fb88b17276122a10bf61"/></dir></target></contents>
|
| 26 |
+
<compatible/>
|
| 27 |
+
<dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
|
| 28 |
+
</package>
|
