Version Notes
Added Multi language support
Download this release
Release Info
Developer | Zealousweb Technologies Pvt Ltd. |
Extension | WhatsApp_Your_Products_using_Magento |
Version | 1.0.0.3 |
Comparing to | |
See all releases |
Code changes from version 1.0.0.2 to 1.0.0.3
- app/code/community/ZealousWeb/WhatsApp/etc/config.xml +9 -0
- app/design/frontend/base/default/template/whatsapp/whatsapp.phtml +6 -3
- app/design/frontend/base/default/template/whatsapp/whatsapp_footer.phtml +9 -4
- app/locale/de_DE/ZealousWeb_WhatsApp.csv +4 -0
- app/locale/en_US/ZealousWeb_WhatsApp.csv +4 -0
- app/locale/fr_FR/ZealousWeb_WhatsApp.csv +4 -0
- package.xml +5 -5
- skin/frontend/base/default/js/whatsapp/whatsapp-button.js +5 -14
app/code/community/ZealousWeb/WhatsApp/etc/config.xml
CHANGED
@@ -46,6 +46,15 @@
|
|
46 |
</whatsapp>
|
47 |
</updates>
|
48 |
</layout>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
49 |
</frontend>
|
50 |
<adminhtml>
|
51 |
<layout>
|
46 |
</whatsapp>
|
47 |
</updates>
|
48 |
</layout>
|
49 |
+
<translate>
|
50 |
+
<modules>
|
51 |
+
<ZealousWeb_WhatsApp>
|
52 |
+
<files>
|
53 |
+
<default>ZealousWeb_WhatsApp.csv</default>
|
54 |
+
</files>
|
55 |
+
</ZealousWeb_WhatsApp>
|
56 |
+
</modules>
|
57 |
+
</translate>
|
58 |
</frontend>
|
59 |
<adminhtml>
|
60 |
<layout>
|
app/design/frontend/base/default/template/whatsapp/whatsapp.phtml
CHANGED
@@ -5,12 +5,15 @@ $productName = $this->getProduct ()->getName ();
|
|
5 |
$productPrice = $this->getProduct ()->getPrice ();
|
6 |
|
7 |
$price_des = "Price: " . $productPrice;
|
8 |
-
$
|
|
|
|
|
|
|
9 |
?>
|
10 |
<?php
|
11 |
if($buttonPos == 1 || $buttonPos == 3)
|
12 |
{
|
13 |
?>
|
14 |
-
<a href="whatsapp://send" data-text='<?php echo $
|
15 |
-
data-href="" class="wa_btn wa_btn_<?php echo $buttonSize?>" style="display:none;"
|
16 |
<?php }?>
|
5 |
$productPrice = $this->getProduct ()->getPrice ();
|
6 |
|
7 |
$price_des = "Price: " . $productPrice;
|
8 |
+
$msg = $this->__("Take a look at this awesome product:");
|
9 |
+
$prd = $this->__($productName);
|
10 |
+
$bmsg = $this->__("at just");
|
11 |
+
$display_des = $msg.' '.$prd.' '.$bmsg.' '.$productPrice;
|
12 |
?>
|
13 |
<?php
|
14 |
if($buttonPos == 1 || $buttonPos == 3)
|
15 |
{
|
16 |
?>
|
17 |
+
<a href="whatsapp://send" data-text='<?php echo $display_des;?>'
|
18 |
+
data-href="" class="wa_btn wa_btn_<?php echo $buttonSize?>" style="display:none;"><?php echo $this->__("Share")?></a>
|
19 |
<?php }?>
|
app/design/frontend/base/default/template/whatsapp/whatsapp_footer.phtml
CHANGED
@@ -7,7 +7,12 @@ $productName = $this->getProduct ()->getName ();
|
|
7 |
$productPrice = $this->getProduct ()->getPrice ();
|
8 |
|
9 |
$price_des = "Price: " . $productPrice;
|
10 |
-
|
|
|
|
|
|
|
|
|
|
|
11 |
?>
|
12 |
<?php
|
13 |
if($buttonPos == 2 || $buttonPos == 3)
|
@@ -24,10 +29,10 @@ if($buttonPos == 2 || $buttonPos == 3)
|
|
24 |
display:none;
|
25 |
">
|
26 |
|
27 |
-
<p
|
28 |
<div>
|
29 |
-
<a href="whatsapp://send" data-text='<?php echo $
|
30 |
-
data-href="" class="wa_btn wa_btn_<?php echo $buttonSize?>" style="display:none;"
|
31 |
</div>
|
32 |
</div>
|
33 |
<?php }?>
|
7 |
$productPrice = $this->getProduct ()->getPrice ();
|
8 |
|
9 |
$price_des = "Price: " . $productPrice;
|
10 |
+
|
11 |
+
$msg = $this->__("Take a look at this awesome product:");
|
12 |
+
$prd = $this->__($productName);
|
13 |
+
$bmsg = $this->__("at just");
|
14 |
+
$display_des = $msg.' '.$prd.' '.$bmsg.' '.$productPrice;
|
15 |
+
|
16 |
?>
|
17 |
<?php
|
18 |
if($buttonPos == 2 || $buttonPos == 3)
|
29 |
display:none;
|
30 |
">
|
31 |
|
32 |
+
<p><?php echo $this->__("Share this link on WhatsApp")?></p>
|
33 |
<div>
|
34 |
+
<a href="whatsapp://send" data-text='<?php echo $display_des;?>'
|
35 |
+
data-href="" class="wa_btn wa_btn_<?php echo $buttonSize?>" style="display:none;"><?php echo $this->__("Share")?></a>
|
36 |
</div>
|
37 |
</div>
|
38 |
<?php }?>
|
app/locale/de_DE/ZealousWeb_WhatsApp.csv
ADDED
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
1 |
+
"Take a look at this awesome product:","Schauen Sie sich auf diesem fantastischen Produkt :"
|
2 |
+
"at just","bei nur"
|
3 |
+
"Share","Aktie"
|
4 |
+
"Share this link on WhatsApp","Diesen Link teilen auf WhatsApp"
|
app/locale/en_US/ZealousWeb_WhatsApp.csv
ADDED
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
1 |
+
"Take a look at this awesome product:","Take a look at this awesome product:"
|
2 |
+
"at just","at just"
|
3 |
+
"Share","Share"
|
4 |
+
"Share this link on WhatsApp","Share this link on WhatsApp"
|
app/locale/fr_FR/ZealousWeb_WhatsApp.csv
ADDED
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
1 |
+
"Take a look at this awesome product:","Jetez un oeil à ce produit génial :"
|
2 |
+
"at just","à seulement"
|
3 |
+
"Share","part"
|
4 |
+
"Share this link on WhatsApp","Partager ce lien sur WhatsApp"
|
package.xml
CHANGED
@@ -1,18 +1,18 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>WhatsApp_Your_Products_using_Magento</name>
|
4 |
-
<version>1.0.0.
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://opensource.org/licenses/osl-3.0.php">OSL-3.0</license>
|
7 |
<channel>community</channel>
|
8 |
<extends/>
|
9 |
<summary>Share Product link to WhatsApp contacts</summary>
|
10 |
<description>Extension will allow you to promote & brand your shop via Whatsapp. Linking this traffic source with a Whatsapp extension would be a huge advantage for your shop promotion & branding, Imagine the traffic you would be able to carry to your website with a source like Whatsapp – the results would be tremendous.</description>
|
11 |
-
<notes>
|
12 |
<authors><author><name>ZealousWeb Technologies Pvt Ltd.</name><user>ZealousWeb</user><email>magento@zealousweb.com</email></author></authors>
|
13 |
-
<date>2015-
|
14 |
-
<time>
|
15 |
-
<contents><target name="magecommunity"><dir><dir name="ZealousWeb"><dir name="WhatsApp"><dir name="Block"><file name="Whatsapp.php" hash="94b3bd283ef5b0e264be9529aaf0b0ca"/></dir><dir name="Helper"><file name="Data.php" hash="0ff493e7177e5ebf41cf7d718fc15149"/></dir><dir name="Model"><file name="Whatsapp.php" hash="6a2395961bdd4a39f4799edd6c143f03"/><file name="Whatsappposition.php" hash="a116fb3b6dbe4b944d0920c8fe07b4c7"/></dir><dir name="etc"><file name="adminhtml.xml" hash="ef11e9213fda8f0f1eb02f3ce5b1496a"/><file name="config.xml" hash="
|
16 |
<compatible/>
|
17 |
<dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
|
18 |
</package>
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>WhatsApp_Your_Products_using_Magento</name>
|
4 |
+
<version>1.0.0.3</version>
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://opensource.org/licenses/osl-3.0.php">OSL-3.0</license>
|
7 |
<channel>community</channel>
|
8 |
<extends/>
|
9 |
<summary>Share Product link to WhatsApp contacts</summary>
|
10 |
<description>Extension will allow you to promote & brand your shop via Whatsapp. Linking this traffic source with a Whatsapp extension would be a huge advantage for your shop promotion & branding, Imagine the traffic you would be able to carry to your website with a source like Whatsapp – the results would be tremendous.</description>
|
11 |
+
<notes>Added Multi language support</notes>
|
12 |
<authors><author><name>ZealousWeb Technologies Pvt Ltd.</name><user>ZealousWeb</user><email>magento@zealousweb.com</email></author></authors>
|
13 |
+
<date>2015-04-23</date>
|
14 |
+
<time>09:28:32</time>
|
15 |
+
<contents><target name="magecommunity"><dir><dir name="ZealousWeb"><dir name="WhatsApp"><dir name="Block"><file name="Whatsapp.php" hash="94b3bd283ef5b0e264be9529aaf0b0ca"/></dir><dir name="Helper"><file name="Data.php" hash="0ff493e7177e5ebf41cf7d718fc15149"/></dir><dir name="Model"><file name="Whatsapp.php" hash="6a2395961bdd4a39f4799edd6c143f03"/><file name="Whatsappposition.php" hash="a116fb3b6dbe4b944d0920c8fe07b4c7"/></dir><dir name="etc"><file name="adminhtml.xml" hash="ef11e9213fda8f0f1eb02f3ce5b1496a"/><file name="config.xml" hash="364d4befa6d006474cac6369211b9af2"/><file name="system.xml" hash="1f3433a08ec5a6aa25a0891d735a5713"/></dir></dir></dir></dir></target><target name="magedesign"><dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="whatsapp.xml" hash="ccad098e02c5c1d44326bc7c001d5ac8"/></dir><dir name="template"><dir name="whatsapp"><file name="whatsapp.phtml" hash="34a16fd4fc8f942a4b52d7e056844538"/><file name="whatsapp_footer.phtml" hash="e3fa5d660c06aca10bc3f2a632db652e"/></dir></dir></dir></dir></dir><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="whatsapp.xml" hash="16965e649db8f000f5b4ec3914703632"/></dir></dir></dir></dir></dir></target><target name="mageetc"><dir><dir name="modules"><file name="ZealousWeb_WhatsApp.xml" hash="707bcd3f24e695683e3a4f45224124f8"/></dir></dir></target><target name="mageskin"><dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="js"><dir name="whatsapp"><file name="whatsapp-button.js" hash="06b3682f1f7d3ee837ba08ba2e3cfd8b"/></dir></dir></dir></dir></dir></dir></target><target name="mageweb"><dir><dir name="js"><dir name="whatsapp"><dir name="jscolor"><file name="arrow.gif" hash="5034704a76cd55c1cbcbc58ea6bf523f"/><file name="cross.gif" hash="ba9a274b9323753cd95bc3b1eb2f4e5f"/><file name="demo.html" hash="edf71251cb2be20322d2efb00aee86a6"/><file name="hs.png" hash="fefa1a03d92ebad25c88dca94a0b63db"/><file name="hv.png" hash="990d71cada17da100653636cf8490884"/><file name="jscolor.js" hash="a26701f49bf33da8dc48f3431e5f4f42"/></dir></dir></dir></dir></target><target name="magelocale"><dir name="en_US"><file name="ZealousWeb_WhatsApp.csv" hash="bb548ccbfe44e530cd4eac507c7ad43d"/></dir><dir name="fr_FR"><file name="ZealousWeb_WhatsApp.csv" hash="cb29fed0e619df3d53b53f53a0f69989"/></dir><dir name="de_DE"><file name="ZealousWeb_WhatsApp.csv" hash="1383230665b1f84d7361e79bf169e4bd"/></dir></target></contents>
|
16 |
<compatible/>
|
17 |
<dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
|
18 |
</package>
|
skin/frontend/base/default/js/whatsapp/whatsapp-button.js
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
waShBtn = function() {
|
2 |
this.isIos === !0 && this.cntLdd(window, this.crBtn)
|
3 |
-
}, waShBtn.prototype.isIos = navigator.userAgent.match(/Android|iPhone/i) && !navigator.userAgent.match(/iPod/i) ? !0 : !1, waShBtn.prototype.cntLdd = function(win, fn) {
|
4 |
var done = !1,
|
5 |
top = !0,
|
6 |
doc = win.document,
|
@@ -31,24 +31,15 @@ waShBtn = function() {
|
|
31 |
}
|
32 |
}, waShBtn.prototype.addStyling = function() {
|
33 |
|
34 |
-
|
35 |
|
36 |
if(x != null)
|
37 |
{
|
38 |
document.getElementById("whats_app_button_footer").style.display = "block";
|
39 |
}
|
40 |
-
//alert(sd);
|
41 |
-
//document.getElementById("whats_app_button_footer").style.backgroundColor = "green";
|
42 |
-
//document.getElementById("whats_app_button_footer").style.align = "center";
|
43 |
|
44 |
var s = document.createElement("style"),
|
45 |
-
c = "body,"
|
46 |
-
"html{padding:0;margin:0;height:100%;width:100%}" +
|
47 |
-
".wa_btn{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLT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A1NS0wLjM4NiwxLjIxNS0wLjc4OWMwLjE2Mi0wLjQwNSwwLjE3Ni0wLjc1NSwwLjEzNS0wLjgzMUMxMS42MzksOS41MjEsMTEuNTIzLDkuNDc1LDExLjM1Miw5LjM3OXoiLz4NCgk8L2c+DQo8L2c+DQo8L3N2Zz4NCg==);border:1px solid rgba(0,0,0,.1);display:inline-block!important;position:relative;font-family:Arial,sans-serif;letter-spacing:.4px;cursor:pointer;font-weight:400;text-transform:none;color:#fff;border-radius:2px;background-color:#5cbe4a;background-repeat:no-repeat;line-height:1.2;text-decoration:none;text-align:left}" +
|
48 |
-
".wa_btn_s{font-size:12px;background-size:16px;background-position:5px 2px;padding:3px 6px 3px 25px}" +
|
49 |
-
".wa_btn_m{font-size:16px;background-size:20px;background-position:4px 2px;padding:4px 6px 4px 30px}" +
|
50 |
-
".wa_btn_l{font-size:16px;background-size:20px;background-position:5px 5px;padding:8px 6px 8px 30px}"
|
51 |
-
;
|
52 |
return s.type = "text/css", s.styleSheet ? s.styleSheet.cssText = c : s.appendChild(document.createTextNode(c)), s
|
53 |
}, waShBtn.prototype.crBtn = function() {
|
54 |
var b = [].slice.call(document.querySelectorAll(".wa_btn"));
|
@@ -58,8 +49,8 @@ waShBtn = function() {
|
|
58 |
t = b[i].getAttribute("data-text"),
|
59 |
u = b[i].getAttribute("data-href"),
|
60 |
o = b[i].getAttribute("href"),
|
61 |
-
at = "?text=" + t;
|
62 |
-
t && (at += "
|
63 |
this.contentDocument.body.appendChild(this.button), this.contentDocument.getElementsByTagName("head")[0].appendChild(theWaShBtn.addStyling());
|
64 |
var meta = document.createElement("meta");
|
65 |
meta.setAttribute("charset", "utf-8"), this.contentDocument.getElementsByTagName("head")[0].appendChild(meta), this.width = Math.ceil(this.contentDocument.getElementsByTagName("a")[0].getBoundingClientRect().width), this.height = Math.ceil(this.contentDocument.getElementsByTagName("a")[0].getBoundingClientRect().height)
|
1 |
waShBtn = function() {
|
2 |
this.isIos === !0 && this.cntLdd(window, this.crBtn)
|
3 |
+
}, waShBtn.prototype.isIos = navigator.userAgent.match(/Android|iPhone/i) && !navigator.userAgent.match(/iPod|iPad/i) ? !0 : !1, waShBtn.prototype.cntLdd = function(win, fn) {
|
4 |
var done = !1,
|
5 |
top = !0,
|
6 |
doc = win.document,
|
31 |
}
|
32 |
}, waShBtn.prototype.addStyling = function() {
|
33 |
|
34 |
+
var x = document.getElementById("whats_app_button_footer");
|
35 |
|
36 |
if(x != null)
|
37 |
{
|
38 |
document.getElementById("whats_app_button_footer").style.display = "block";
|
39 |
}
|
|
|
|
|
|
|
40 |
|
41 |
var s = document.createElement("style"),
|
42 |
+
c = "body,html{padding:0;margin:0;height:100%;width:100%}.wa_btn{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4NCjwhLS0gR2VuZXJhdG9yOiBBZG9iZSBJbGx1c3RyYXRvciAxNi4wLjAsIFNWRyBFeHBvcnQgUGx1Zy1JbiAuIFNWRyBWZXJzaW9uOiA2LjAwIEJ1aWxkIDApICAtLT4NCjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9XM0MvL0RURCBTVkcgMS4xLy9FTiIgImh0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCI+DQo8c3ZnIHZlcnNpb249IjEuMSIgaWQ9IkViZW5lXzEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4Ig0KCSB3aWR0aD0iMTZweCIgaGVpZ2h0PSIxNnB4IiB2aWV3Qm94PSIwIDAgMTYgMTYiIGVuYWJsZS1iYWNrZ3JvdW5kPSJuZXcgMCAwIDE2IDE2IiB4bWw6c3BhY2U9InByZXNlcnZlIj4NCjxnPg0KCTxnPg0KCQk8cGF0aCBmaWxsLX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JCQljMC4wNjItMC4xMTUsMC4wMzgtMC4yMTgtMC4wMDMtMC4zMDhDNy4wMTIsNi4wMjMsNi42OTQsNS4xNDYsNi41NjEsNC43OUM2LjQyOCw0LjQzNCw2LjI4LDQuNDg2LDYuMTc3LDQuNDgyDQoJCQlDNi4wNzUsNC40NzksNS45NTgsNC40NTksNS44NDEsNC40NTZDNS43MjQsNC40NTEsNS41MzMsNC40ODcsNS4zNjYsNC42NTdjLTAuMTY3LDAuMTctMC42MzcsMC41NzYtMC42NjksMS40MzkNCgkJCXMwLjU2NSwxLjcyMiwwLjY0OCwxLjg0MWMwLjA4NCwwLjEyMSwxLjE0LDEuOTkxLDIuODk3LDIuNzYyYzEuNzU2LDAuNzcsMS43NjYsMC41MzQsMi4wODgsMC41MTgNCgkJCWMwLjMyMi0wLjAxOCwxLjA1NS0wLjM4NiwxLjIxNS0wLjc4OWMwLjE2Mi0wLjQwNSwwLjE3Ni0wLjc1NSwwLjEzNS0wLjgzMUMxMS42MzksOS41MjEsMTEuNTIzLDkuNDc1LDExLjM1Miw5LjM3OXoiLz4NCgk8L2c+DQo8L2c+DQo8L3N2Zz4NCg==);border:1px solid rgba(0,0,0,.1);display:inline-block!important;position:relative;font-family:Arial,sans-serif;letter-spacing:.4px;cursor:pointer;font-weight:400;text-transform:none;color:#fff;border-radius:2px;background-color:#5cbe4a;background-repeat:no-repeat;line-height:1.2;text-decoration:none;text-align:left}.wa_btn_s{font-size:12px;background-size:16px;background-position:5px 2px;padding:3px 6px 3px 25px}.wa_btn_m{font-size:16px;background-size:20px;background-position:4px 2px;padding:4px 6px 4px 30px}.wa_btn_l{font-size:16px;background-size:20px;background-position:5px 5px;padding:8px 6px 8px 30px}";
|
|
|
|
|
|
|
|
|
|
|
|
|
43 |
return s.type = "text/css", s.styleSheet ? s.styleSheet.cssText = c : s.appendChild(document.createTextNode(c)), s
|
44 |
}, waShBtn.prototype.crBtn = function() {
|
45 |
var b = [].slice.call(document.querySelectorAll(".wa_btn"));
|
49 |
t = b[i].getAttribute("data-text"),
|
50 |
u = b[i].getAttribute("data-href"),
|
51 |
o = b[i].getAttribute("href"),
|
52 |
+
at = "?text=" + encodeURIComponent(t);
|
53 |
+
t && (at += "%20"), at += encodeURIComponent(u ? u : document.URL), b[i].setAttribute("href", o + at), b[i].setAttribute("target", "_top"), iframe[i] = document.createElement("iframe"), iframe[i].width = 1, iframe[i].height = 1, iframe[i].button = b[i], iframe[i].style.border = 0, iframe[i].style.overflow = "hidden", iframe[i].border = 0, iframe[i].setAttribute("scrolling", "no"), iframe[i].addEventListener("load", function() {
|
54 |
this.contentDocument.body.appendChild(this.button), this.contentDocument.getElementsByTagName("head")[0].appendChild(theWaShBtn.addStyling());
|
55 |
var meta = document.createElement("meta");
|
56 |
meta.setAttribute("charset", "utf-8"), this.contentDocument.getElementsByTagName("head")[0].appendChild(meta), this.width = Math.ceil(this.contentDocument.getElementsByTagName("a")[0].getBoundingClientRect().width), this.height = Math.ceil(this.contentDocument.getElementsByTagName("a")[0].getBoundingClientRect().height)
|