Subversion Repositories SmartDukaan

Rev

Rev 7011 | Rev 7051 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
6967 kshitij.so 1
function toggle(containerId){
2
        var divC = document.getElementById(containerId);
3
        if (divC.style.display == 'none') {
4
            divC.style.display = 'block';
5
        } else if (divC.style.display == 'block'){
6
            divC.style.display = 'none';
7
        }
8
        else {
9
        	divC.style.display = 'none';
10
        }
11
    }
12
 
4126 varun.gupt 13
$(function(){
4984 varun.gupt 14
	function CollapsibleWidget(container)	{
15
 
16
		this.widgetContainer = container;
17
		this.collapsbiles = $(container).children('.common-widget-control-bar, .common-widget-content-area');
18
		this.isCollapsed = null;
19
 
20
		this.collapse = function()	{
21
			$(this.collapsbiles).each(function()	{
22
				$(this).slideUp();
23
			});
24
			this.isCollapsed = true;
25
		};
26
 
27
		this.open = function()	{
28
			$(this.collapsbiles).each(function()	{
29
				$(this).slideDown();
30
			});
31
			this.isCollapsed = false;
32
		};
33
 
34
		this.test = function()	{
35
		};
36
	}
4798 varun.gupt 37
 
4984 varun.gupt 38
	ResearchWidget.prototype = new CollapsibleWidget();
39
	ResearchWidget.prototype.constructor = CollapsibleWidget;
40
 
41
	function ResearchWidget(container)	{
42
		CollapsibleWidget.call(this, container);
43
	}
44
 
4798 varun.gupt 45
	function updateCompareCount()	{
46
		$('#research_compare_count').html($('#myresearch input[type="checkbox"]:checked').length);
47
	}
48
 
4126 varun.gupt 49
	/** Sidebar Widgets **/
4237 varun.gupt 50
 
6840 kshitij.so 51
	$('#otg_know_more,.otg_know_more').click(function(){
6552 kshitij.so 52
		$.colorbox({
53
    		width: "490px",
6772 kshitij.so 54
    		height: "420px",
6552 kshitij.so 55
    		inline: true,
56
    		href: "<h3 style='text-align: center; margin: 18px; font-size: 14px;'>On Time Guarantee, We Pay if we Delay</h3>" +
57
		"<p style='text-align: justify; margin-left: 12px; margin-right: 12px; margin-bottom: 9px; line-height: 22px;'>Saholic stands for 100% on time delivery. We ensure all your orders reach your doorstep on or "+
58
        "before the promised delivery date. In the rare case that we deliver an order later than promised "+
59
        "we will compensate you.This Guarantee is Valid on"+
60
        "</p>" +
61
        "<ul style='list-style: disc none none; margin-left: 25px; text-align: justify; margin-right:12px; line-height: 22px;'><li>All Mobiles, Cameras, Laptops, Tablets and Accessories above Rs. 2000 in value."+
62
        "</li>"+
63
        "<li>Orders Placed using Credit/Debit Card, Net Banking, EMI, Prepaid Cash Cards."+
64
        "</li>"+
65
        "</ul>"+
6772 kshitij.so 66
        "<p style='text-align: justify; line-height: 22px; margin: 12px;'>Compensation for delay is in the form of Gift Vouchers at the rate of Rs. 50 per business day. " +
67
        "GV can be applied to ANY product on Saholic.com without limitation.</p>"+
6598 amit.gupta 68
        "<span class='right'><a target='_blank' href='/static/on-time-guarantee' style='margin-right: 12px';>Detailed Terms & Conditions</a></span>",
6552 kshitij.so 69
        onComplete: function(){
70
		trackEventWithGA('Widget', 'OTG Know More is clicked', '');
71
			}
72
    	});
73
	});
74
 
4237 varun.gupt 75
	$('#shoppingExpInfo').click(function(){
76
		$.colorbox({
4284 varun.gupt 77
    		width: "550px",
78
    		height: "320px",
4237 varun.gupt 79
    		inline: true,
80
    		href: "<h3>Shopping with Saholic.com is completely safe</h3><br />" +
4284 varun.gupt 81
		"<b>1.</b> We are part of Spice Group - India's # 1 Mobile retailer.<br /><br />" +
82
		"<b>2.</b> We procure directly from the Manufacturers - Hence we only sell genuine products with full Manufacturer Warranty.<br /><br />" +
83
		"<b>3.</b> We provide free Next Day Delivery to most locations - You can check the delivery time to your location by entering your pin code on the product page.<br /><br />" +
6173 kshitij.so 84
		"<b>4.</b> We use the best Internet Security technology - Your payment is 100% secure.<br />",
4372 varun.gupt 85
			onComplete: function(){
6261 amit.gupta 86
				trackEventWithGA('Widget', 'Safe shopping sticky banner is clicked', '');
4372 varun.gupt 87
			}
4237 varun.gupt 88
    	});
89
	});
6245 kshitij.so 90
 
6552 kshitij.so 91
 
6970 kshitij.so 92
	$('.insuranceInfo').click(function(){
93
		$.colorbox({
94
    		width: "520px",
95
    		height: "280px",
96
    		inline: true,
97
    		href: "<h3 style='font-size:15px; text-align:center; font-weight:bold; margin-left:15px; margin-top:5px;margin-bottom:10px'>Exclusively at Saholic</h3>" +
98
    		"<ul style='text-align: justify; padding-right: 10px; width: 93%; padding-left: 16px; line-height: 25px;'>"+
99
    		"<li>Only Saholic brings to you an option to protect your smartphone against theft and burglary.</li>"+
100
    		"<li>While buying your favourite mobile from Saholic, you can opt for 1 year WorldWide theft insurance.</li>"+
101
    		"<li>Introductory offer - You can opt for insurance by paying an all inclusive nominal fee of 1.5% of price of your mobile.</li>"+
102
    		"<a target='_blank' href='/static/insurance-terms' style='float: right; text-decoration: none;'>Detailed Terms and Conditions</a>"+
103
    		"</ul>",
104
			onComplete: function(){
105
				trackEventWithGA('Widget', 'Insurance sticky banner is clicked', '');
106
			}
107
    	});
108
	});
109
 
110
 
6959 kshitij.so 111
	$('.emiInfo').click(function(){
6453 kshitij.so 112
		$.colorbox({
6967 kshitij.so 113
    		width: "590px",
114
    		height: "480px",
6453 kshitij.so 115
    		inline: true,
6970 kshitij.so 116
    		href: "<br />" +
6967 kshitij.so 117
    		"<div style='display: inline-block; padding-left: 5px;' class='bank-logo'><img src='/images/hdfc-icon.png' style='vertical-align: middle;'></div>"+
7011 kshitij.so 118
    		"<div class='emi-text' style='text-align: justify; height: 49px; padding-left: 3px; width: 397px; display: inline-block; vertical-align: top;'><p style='height: 38px; width: 420px;'>Available for 3, 6, 9, 12 and 18 months. Completely free for 3 months.<br><a onclick='toggle(\"emi-table-hdfc\");' style='cursor: pointer; text-decoration: none;'>See Full Details</a></p></div>"+
6967 kshitij.so 119
    		"<div id='emi-table-hdfc' style='padding-left: 5px; display: none;'>"+
120
    		"<table width='85%' cellspacing='0' cellpadding='0' border='0' id='emiwidget' style='padding-top: 2px; padding-bottom: 2px; border-top-width: 0px; border-left-width: 0px;padding-left: 5px'>"+
121
    		"<thead>"+
122
            "<th style='border:1px solid gray;text-align: center;background-color: #F1F1F1;' colspan='5'>All Inclusive Processing Fee*</th>"+
123
            "</thead>"+
124
            "<tbody>"+
125
            "<tr>"+
126
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>3 Months</th>"+
127
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>6 Months</th>"+
128
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>9 Months</th>"+
7011 kshitij.so 129
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>12 Months</th>"+
130
            "<td style='border-width: 0px 1px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>18 Months</th>"+
6967 kshitij.so 131
            "</tr>"+
132
            "<tr>"+
133
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>Free</td>"+
134
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>4.22%</td>"+
135
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>7.04%</td>"+
7011 kshitij.so 136
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>9.67%</td>"+
137
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 1px solid gray;text-align: center;'>15.36%</td>"+
6967 kshitij.so 138
            "</tr>"+
139
            "</tbody>"+
140
            "</table>"+
141
            "<br>"+
142
    		"<ul style='list-style : disc none none; padding-left: 20px; text-align:justify; line-height: 13px; padding-right: 10px; width: 83%;'>"+
143
    		"<li>Select EMI on Make Payment Page to see Monthly EMI payable and Total Amount Payable.</li>"+
6772 kshitij.so 144
    		"<br>"+
6967 kshitij.so 145
    		"<li>No charges will be levied by the bank.</li><br><li>Credit limit of full amount is needed and blocked at the time of buying on EMI.</li><br><li>As you pay the installments, correspondingly your credit limit increases.</li>"+
146
    		"</ul>"+
6959 kshitij.so 147
    		"<br>"+
6967 kshitij.so 148
    		"</div>"+
149
    		"<div style='display: inline-block; padding-left: 5px;' class='bank-logo'><img src='/images/citi-icon.png' style='vertical-align: middle;'></div>"+
150
    		"<div class='emi-text' style='text-align: justify; height: 49px; padding-left: 3px; width: 397px; display: inline-block; vertical-align: top;'><p style='height: 38px; width: 420px;'>Available for 3 and 6 months. Completely free for 3 months. <br><a onclick='javascript:toggle(\"emi-table-citi\");' style='cursor: pointer; text-decoration: none;'>See Full Details</a></p></div>"+
151
    		"<div id='emi-table-citi' style='padding-left: 5px;display: none;'>"+
6970 kshitij.so 152
    		"<table width='70%' cellspacing='0' cellpadding='0' border='0' id='emiwidget' style='padding-top: 2px; padding-bottom: 2px; border-top-width: 0px; border-left-width: 0px;padding-left: 5px'>"+
6967 kshitij.so 153
    		"<thead>"+
154
            "<th style='border:1px solid gray;text-align: center;background-color: #F1F1F1;' colspan='2'>All Inclusive Processing Fee*</th>"+
6772 kshitij.so 155
            "</thead>"+
156
            "<tbody>"+
157
            "<tr>"+
6970 kshitij.so 158
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 35%;'>3 Months</th>"+
159
            "<td style='border-width: 0px 1px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 35%;'>6 Months</th>"+
6967 kshitij.so 160
            "</tr>"+
161
            "<tr>"+
162
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>Free</td>"+
163
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 1px solid gray; text-align: center;'>4.22%</td>"+
164
            "</tr>"+
165
            "</tbody>"+
166
            "</table>"+
167
            "<br>"+
168
    		"<ul style='list-style : disc none none; padding-left: 20px; text-align:justify; line-height: 13px; padding-right: 10px; width: 83%;'>"+
169
    		"<li>Select EMI on Make Payment Page to see Monthly EMI payable and Total Amount Payable.</li>"+
170
    		"<br>"+
171
    		"<li>No charges will be levied by the bank.</li><br><li>Credit limit of full amount is needed and blocked at the time of buying on EMI.</li><br><li>As you pay the installments, correspondingly your credit limit increases.</li>"+
172
    		"</ul>"+
173
    		"<br>"+
174
    		"</div>"+
175
    		"<div style='display: inline-block; padding-left: 5px;' class='bank-logo'><img src='/images/icici-icon.png' style='vertical-align: middle;'></div>"+
176
    		"<div class='emi-text' style='text-align: justify; height: 49px; padding-left: 3px; width: 397px; display: inline-block; vertical-align: top;'><p style='height: 38px; width: 420px;'>Available for 3, 6, 9 ,12 and 18 months. <br><a  onclick='javascript:toggle(\"emi-table-icici\");' style='cursor: pointer; text-decoration: none;'>See Full Details</a></p></div>"+
177
    		"<div id='emi-table-icici' style='padding-left: 5px;display: none;'>"+
178
    		"<table width='85%' cellspacing='0' cellpadding='0' border='0' id='emiwidget' style='padding-top: 2px; padding-bottom: 2px; border-top-width: 0px; border-left-width: 0px;padding-left: 5px'>"+
179
    		"<thead>"+
6970 kshitij.so 180
            "<th style='border:1px solid gray;text-align: center;background-color: #F1F1F1;' colspan='5'>All Inclusive Processing Fee*</th>"+
6967 kshitij.so 181
            "</thead>"+
182
            "<tbody>"+
183
            "<tr>"+
184
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>3 Months</th>"+
6959 kshitij.so 185
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>6 Months</th>"+
186
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>9 Months</th>"+
187
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>12 Months</th>"+
188
            "<td style='border-width: 0px 1px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>18 Months</th>"+
189
            "</tr>"+
6772 kshitij.so 190
            "<tr>"+
6967 kshitij.so 191
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>3.13%</td>"+
192
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>5.58%</td>"+
193
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>8.47%</td>"+
194
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>11.53%</td>"+
195
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 1px solid gray;text-align: center;'>16.72%</td>"+
6772 kshitij.so 196
            "</tr>"+
6967 kshitij.so 197
            "</tbody>"+
198
            "</table>"+
199
            "<br>"+
200
    		"<ul style='list-style : disc none none; padding-left: 20px; text-align:justify; line-height: 13px; padding-right: 10px; width: 83%;'>"+
201
    		"<li>Select EMI on Make Payment Page to see Monthly EMI payable and Total Amount Payable.</li>"+
202
    		"<br>"+
6970 kshitij.so 203
    		"<li>No charges will be levied by the bank.</li><br><li>Credit limit of full amount is needed and blocked at the time of buying on EMI.</li><br><li>As you pay the installments, correspondingly your credit limit increases.</li><br><li>Minimum payment amount required to convert into EMI is Rs 1500.</li>"+
6967 kshitij.so 204
    		"</ul>"+
205
    		"<br>"+
206
    		"</div>"+
207
    		"<div style='display: inline-block; padding-left: 5px;' class='bank-logo'><img src='/images/sbi-icon.png' style='vertical-align: middle;'></div>"+
208
    		"<div class='emi-text' style='text-align: justify; height: 49px; padding-left: 3px; width: 397px; display: inline-block; vertical-align: top;'><p style='height: 38px; width: 420px;'>Available for 3, 6, 9 ,12 and 18 months. <br><a onclick='javascript:toggle(\"emi-table-sbi\");' style='cursor: pointer; text-decoration: none;'>See Full Details</a></p></div>"+
209
    		"<div id='emi-table-sbi' style='padding-left: 5px;display: none;'>"+
210
    		"<table width='85%' cellspacing='0' cellpadding='0' border='0' id='emiwidget' style='padding-top: 2px; padding-bottom: 2px; border-top-width: 0px; border-left-width: 0px;padding-left: 5px'>"+
211
    		"<thead>"+
6970 kshitij.so 212
            "<th style='border:1px solid gray;text-align: center;background-color: #F1F1F1;' colspan='5'>All Inclusive Processing Fee*</th>"+
6967 kshitij.so 213
            "</thead>"+
214
            "<tbody>"+
6772 kshitij.so 215
            "<tr>"+
6967 kshitij.so 216
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>3 Months</th>"+
217
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>6 Months</th>"+
218
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>9 Months</th>"+
219
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>12 Months</th>"+
220
            "<td style='border-width: 0px 1px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>18 Months</th>"+
6772 kshitij.so 221
            "</tr>"+
222
            "<tr>"+
6967 kshitij.so 223
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>3.13%</td>"+
224
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>5.58%</td>"+
225
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>8.47%</td>"+
226
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>11.53%</td>"+
227
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 1px solid gray;text-align: center;'>16.72%</td>"+
228
            "</tr>"+
229
            "</tbody>"+
230
            "</table>"+
231
            "<br>"+
232
    		"<ul style='list-style : disc none none; padding-left: 20px; text-align:justify; line-height: 13px; padding-right: 10px; width: 83%;'>"+
233
    		"<li>Select EMI on Make Payment Page to see Monthly EMI payable and Total Amount Payable.</li>"+
234
    		"<br>"+
6970 kshitij.so 235
    		"<li>No charges will be levied by the bank.</li><br><li>Credit limit of full amount is needed and blocked at the time of buying on EMI.</li><br><li>As you pay the installments, correspondingly your credit limit increases.</li><br><li>Minimum payment amount required to convert into EMI is Rs 1000.</li>"+
6967 kshitij.so 236
    		"</ul>"+
237
    		"<br>"+
238
    		"</div>"+
239
    		"<div style='display: inline-block; padding-left: 5px;' class='bank-logo'><img src='/images/hsbc-icon.png' style='vertical-align: middle;'></div>"+
7017 kshitij.so 240
    		"<div class='emi-text' style='text-align: justify; height: 49px; padding-left: 3px; width: 397px; display: inline-block; vertical-align: top;'><p style='height: 38px; width: 420px;'>Available for 3, 6, 9 and 12 months. <br><a onclick='javascript:toggle(\"emi-table-hsbc\");' style='cursor: pointer; text-decoration: none;'>See Full Details</a></p></div>"+
6967 kshitij.so 241
    		"<div id='emi-table-hsbc' style='padding-left: 5px;display:none;'>"+
6970 kshitij.so 242
    		"<table width='70%' cellspacing='0' cellpadding='0' border='0' id='emiwidget' style='padding-top: 2px; padding-bottom: 2px; border-top-width: 0px; border-left-width: 0px;padding-left: 5px'>"+
6967 kshitij.so 243
    		"<thead>"+
6970 kshitij.so 244
            "<th style='border:1px solid gray;text-align: center;background-color: #F1F1F1;' colspan='5'>All Inclusive Processing Fee*</th>"+
6967 kshitij.so 245
            "</thead>"+
246
            "<tbody>"+
247
            "<tr>"+
7017 kshitij.so 248
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>3 Months</th>"+
249
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>6 Months</th>"+
250
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>9 Months</th>"+
251
            "<td style='border-width: 0px 1px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>12 Months</th>"+
6967 kshitij.so 252
            "</tr>"+
253
            "<tr>"+
254
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>3.13%</td>"+
7017 kshitij.so 255
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>5.58%</td>"+
256
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>8.47%</td>"+
257
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 1px solid gray;text-align: center;'>11.53%</td>"+
6772 kshitij.so 258
            "</tr>"+
6967 kshitij.so 259
            "</tbody>"+
260
            "</table>"+
261
            "<br>"+
262
    		"<ul style='list-style : disc none none; padding-left: 20px; text-align:justify; line-height: 13px; padding-right: 10px; width: 83%;'>"+
263
    		"<li>Select EMI on Make Payment Page to see Monthly EMI payable and Total Amount Payable.</li>"+
264
    		"<br>"+
6970 kshitij.so 265
    		"<li>No charges will be levied by the bank.</li><br><li>Credit limit of full amount is needed and blocked at the time of buying on EMI.</li><br><li>As you pay the installments, correspondingly your credit limit increases.</li><br><li>Minimum payment amount required to convert into EMI is Rs 1500.</li>"+
6967 kshitij.so 266
    		"</ul>"+
267
    		"<br>"+
268
    		"</div>"+
269
    		"<div style='display: inline-block; padding-left: 5px;' class='bank-logo'><img src='/images/std-chartered-icon.png' style='vertical-align: middle;'></div>"+
270
    		"<div class='emi-text' style='text-align: justify; height: 49px; padding-left: 3px; width: 397px; display: inline-block; vertical-align: top;'><p style='height: 38px; width: 420px;'>Available for 3, 6, 9 and 12 months. <br><a onclick='javascript:toggle(\"emi-table-std-chart\");' style='cursor: pointer; text-decoration: none;'>See Full Details</a></p></div>"+
271
    		"<div id='emi-table-std-chart' style='padding-left: 5px;display: none;'>"+
272
    		"<table width='85%' cellspacing='0' cellpadding='0' border='0' id='emiwidget' style='padding-top: 2px; padding-bottom: 2px; border-top-width: 0px; border-left-width: 0px;padding-left: 5px'>"+
273
    		"<thead>"+
6970 kshitij.so 274
            "<th style='border:1px solid gray;text-align: center;background-color: #F1F1F1;' colspan='5'>All Inclusive Processing Fee*</th>"+
6967 kshitij.so 275
            "</thead>"+
276
            "<tbody>"+
6772 kshitij.so 277
            "<tr>"+
6970 kshitij.so 278
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%%;'>3 Months</th>"+
6967 kshitij.so 279
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>6 Months</th>"+
280
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>9 Months</th>"+
281
            "<td style='border-width: 0px 1px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>12 Months</th>"+
6772 kshitij.so 282
            "</tr>"+
283
            "<tr>"+
6967 kshitij.so 284
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>3.13%</td>"+
285
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>5.58%</td>"+
286
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>8.47%</td>"+
287
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 1px solid gray;text-align: center;'>11.53%</td>"+
6772 kshitij.so 288
            "</tr>"+
6967 kshitij.so 289
            "</tbody>"+
290
            "</table>"+
291
            "<br>"+
292
    		"<ul style='list-style : disc none none; padding-left: 20px; text-align:justify; line-height: 13px; padding-right: 10px; width: 83%;'>"+
293
    		"<li>Select EMI on Make Payment Page to see Monthly EMI payable and Total Amount Payable.</li>"+
294
    		"<br>"+
6970 kshitij.so 295
    		"<li>No charges will be levied by the bank.</li><br><li>Credit limit of full amount is needed and blocked at the time of buying on EMI.</li><br><li>As you pay the installments, correspondingly your credit limit increases.</li><br><li>Minimum payment amount required to convert into EMI is Rs 2500.</li>"+
6967 kshitij.so 296
    		"</ul>"+
297
    		"<br>"+
298
    		"</div>"+
299
    		"<div style='display: inline-block; padding-left: 5px;' class='bank-logo'><img src='/images/kotak-icon.png' style='vertical-align: middle;'></div>"+
300
    		"<div class='emi-text' style='text-align: justify; height: 49px; padding-left: 3px; width: 397px; display: inline-block; vertical-align: top;'><p style='height: 38px; width: 420px;'>Available for 3, 6, 9 and 12 months. <br><a onclick='javascript:toggle(\"emi-table-kotak\");' style='cursor: pointer; text-decoration: none;'>See Full Details</a></p></div>"+
301
    		"<div id='emi-table-kotak' style='padding-left: 5px;display: none;'>"+
302
    		"<table width='85%' cellspacing='0' cellpadding='0' border='0' id='emiwidget' style='padding-top: 2px; padding-bottom: 2px; border-top-width: 0px; border-left-width: 0px;padding-left: 5px'>"+
303
    		"<thead>"+
6970 kshitij.so 304
            "<th style='border:1px solid gray;text-align: center;background-color: #F1F1F1;' colspan='5'>All Inclusive Processing Fee*</th>"+
6967 kshitij.so 305
            "</thead>"+
306
            "<tbody>"+
6959 kshitij.so 307
            "<tr>"+
6967 kshitij.so 308
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>3 Months</th>"+
309
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>6 Months</th>"+
310
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>9 Months</th>"+
311
            "<td style='border-width: 0px 1px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>12 Months</th>"+
6959 kshitij.so 312
            "</tr>"+
313
            "<tr>"+
6967 kshitij.so 314
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>3.13%</td>"+
315
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>5.58%</td>"+
316
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>8.47%</td>"+
317
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 1px solid gray;text-align: center;'>11.53%</td>"+
318
            "</tr>"+
319
            "</tbody>"+
320
            "</table>"+
321
            "<br>"+
322
    		"<ul style='list-style : disc none none; padding-left: 20px; text-align:justify; line-height: 13px; padding-right: 10px; width: 83%;'>"+
323
    		"<li>Select EMI on Make Payment Page to see Monthly EMI payable and Total Amount Payable.</li>"+
324
    		"<br>"+
6970 kshitij.so 325
    		"<li>No charges will be levied by the bank.</li><br><li>Credit limit of full amount is needed and blocked at the time of buying on EMI.</li><br><li>As you pay the installments, correspondingly your credit limit increases.</li><br><li>Minimum payment amount required to convert into EMI is Rs 500.</li>"+
6967 kshitij.so 326
    		"</ul>"+
327
    		"<br>"+
328
    		"</div>"+
329
    		"<div style='display: inline-block; padding-left: 5px;' class='bank-logo'><img src='/images/axis-icon.png' style='vertical-align: middle;'></div>"+
330
    		"<div class='emi-text' style='text-align: justify; height: 49px; padding-left: 3px; width: 397px; display: inline-block; vertical-align: top;'><p style='height: 38px; width: 420px;'>Available for 3, 6, 9 ,12 and 18 months. <br><a onclick='javascript:toggle(\"emi-table-axis\");' style='cursor: pointer; text-decoration: none;'>See Full Details</a></p></div>"+
331
    		"<div id='emi-table-axis' style='padding-left: 5px;display: none;'>"+
332
    		"<table width='85%' cellspacing='0' cellpadding='0' border='0' id='emiwidget' style='padding-top: 2px; padding-bottom: 2px; border-top-width: 0px; border-left-width: 0px;padding-left: 5px'>"+
333
    		"<thead>"+
6970 kshitij.so 334
            "<th style='border:1px solid gray;text-align: center;background-color: #F1F1F1;' colspan='5'>All Inclusive Processing Fee*</th>"+
6967 kshitij.so 335
            "</thead>"+
336
            "<tbody>"+
337
            "<tr>"+
338
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>3 Months</th>"+
339
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>6 Months</th>"+
340
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>9 Months</th>"+
341
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>12 Months</th>"+
342
            "<td style='border-width: 0px 1px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>18 Months</th>"+
343
            "</tr>"+
344
            "<tr>"+
345
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>3.13%</td>"+
346
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>5.58%</td>"+
347
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>8.47%</td>"+
348
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>11.53%</td>"+
349
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 1px solid gray;text-align: center;'>16.72%</td>"+
6959 kshitij.so 350
            "</tr>"+
6967 kshitij.so 351
            "</tbody>"+
352
            "</table>"+
353
            "<br>"+
354
    		"<ul style='list-style : disc none none; padding-left: 20px; text-align:justify; line-height: 13px; padding-right: 10px; width: 83%;'>"+
355
    		"<li>Select EMI on Make Payment Page to see Monthly EMI payable and Total Amount Payable.</li>"+
356
    		"<br>"+
6970 kshitij.so 357
    		"<li>No charges will be levied by the bank.</li><br><li>Credit limit of full amount is needed and blocked at the time of buying on EMI.</li><br><li>As you pay the installments, correspondingly your credit limit increases.</li><br><li>Minimum payment amount required to convert into EMI is Rs 2500.</li>"+
6967 kshitij.so 358
    		"</ul>"+
359
    		"<br>"+
360
    		"</div>"+
361
    		"<div style='display: inline-block; padding-left: 5px;' class='bank-logo'><img src='/images/indusind-icon.png' style='vertical-align: middle;'></div>"+
362
    		"<div class='emi-text' style='text-align: justify; height: 49px; padding-left: 3px; width: 397px; display: inline-block; vertical-align: top;'><p style='height: 38px; width: 420px;'>Available for 3, 6, 9 and 12 months. <br><a onclick='javascript:toggle(\"emi-table-indus\");' style='cursor: pointer; text-decoration: none;'>See Full Details</a></p></div>"+
363
    		"<div id='emi-table-indus' style='padding-left: 5px;display: none;'>"+
364
    		"<table width='85%' cellspacing='0' cellpadding='0' border='0' id='emiwidget' style='padding-top: 2px; padding-bottom: 2px; border-top-width: 0px; border-left-width: 0px;padding-left: 5px'>"+
365
    		"<thead>"+
366
            "<th style='border:1px solid gray;text-align: center;background-color: #F1F1F1;' colspan='5'>All Inclusive Processing Fee*</th>"+
367
            "</thead>"+
368
            "<tbody>"+
6959 kshitij.so 369
            "<tr>"+
6967 kshitij.so 370
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>3 Months</th>"+
371
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>6 Months</th>"+
372
            "<td style='border-width: 0px 0px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>9 Months</th>"+
373
            "<td style='border-width: 0px 1px 1px 1px; border-style: solid; border-color: gray;text-align: center; width: 9%;'>12 Months</th>"+
6959 kshitij.so 374
            "</tr>"+
375
            "<tr>"+
6967 kshitij.so 376
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>3.13%</td>"+
377
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>5.58%</td>"+
378
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 0px solid gray; text-align: center;'>8.47%</td>"+
379
            "<td style='border-bottom: 1px solid gray; border-left: 1px solid gray; border-right: 1px solid gray;text-align: center;'>11.53%</td>"+
6959 kshitij.so 380
            "</tr>"+
6772 kshitij.so 381
            "</tbody>"+
382
            "</table>"+
383
            "<br>"+
6967 kshitij.so 384
    		"<ul style='list-style : disc none none; padding-left: 20px; text-align:justify; line-height: 13px; padding-right: 10px; width: 83%;'>"+
385
    		"<li>Select EMI on Make Payment Page to see Monthly EMI payable and Total Amount Payable.</li>"+
386
    		"<br>"+
387
    		"<li>No charges will be levied by the bank.</li><br><li>Credit limit of full amount is needed and blocked at the time of buying on EMI.</li><br><li>As you pay the installments, correspondingly your credit limit increases.</li>"+
388
    		"</ul>"+
389
    		"<br>"+
390
    		"</div>"+
391
    		"<br><br>",
6453 kshitij.so 392
			onComplete: function(){
393
				trackEventWithGA('Widget', 'Emi info widget is clicked', '');
394
			}
395
    	});
396
	});
6245 kshitij.so 397
 
6792 vikram.rag 398
	$('a.mk_best_deal_detail').live('click', function(){
399
		var offerLinkHtml = '';
400
		if(OFFER_HELP_LINK!='$OFFER_DETAIL_LINK') {
6795 vikram.rag 401
			offerLinkHtml = '<a target="_blank" href="' +OFFER_HELP_LINK + '" style="z-index: 1; float: right; bottom: 0px; right: 0px; margin: 15px; position: relative;">More</a></span>';
6792 vikram.rag 402
		}
403
		$.colorbox({
404
			width: "550px",
405
    		height: "300px",
406
    		inline: true,
407
    		href: '<h3 style="text-align: left; padding: 10px;">Offer Details</h3>' +
408
    			'<p style="text-align: justify; line-height: 22px; margin: 12px;">' + OFFER_HELP_TEXT +
409
    			'</p><span class="right">' + offerLinkHtml 
410
		});
411
	});
6453 kshitij.so 412
 
6792 vikram.rag 413
 
6245 kshitij.so 414
	$('#pickupstoreInfo').click(function(){
415
		$.colorbox({
416
    		width: "550px",
417
    		height: "370px",
418
    		inline: true,
419
    		href: "<h3>Frequently Asked Questions</h3><br />" +
420
		"<b>Q)</b> What is 'Buy Online & Pickup in Store' ?<br /><br />" +
421
		"<b>A)</b> Buy Online from Saholic.Com and pickup your product from the nearest Spice Hotspot Retail Store.<br /><br />" +
422
		"<b>Q)</b> How do i avail this facility ?<br /><br />" +
423
		"<b>A)</b> Simply select Pickup In Store On the Shipping Page and select your nearest store. Please note this facility is available only in Delhi/NCR.</a><br /><br />"+
424
		"<b>Q)</b> When will the product be available for pickup ?<br /><br />" +
425
		"<b>A)</b> You can enter your pin code on the Product Page to find estimated time to deliver. After placing the order we will also give you the estimated date for pickup.</a><br /><br />",
426
 
427
			onComplete: function(){
6262 amit.gupta 428
				var ev = "Product Page";
6303 amit.gupta 429
				var label = window.location.pathname;
6264 amit.gupta 430
				if (label=="" || label=="#")
6261 amit.gupta 431
				{
6303 amit.gupta 432
					label = "";
6262 amit.gupta 433
					ev = "Home Page";
6261 amit.gupta 434
				}
6262 amit.gupta 435
				else if (label.indexOf("shipping") != -1){
436
					ev = "Shipping Page";
437
					var blkstr = [];
6263 amit.gupta 438
					jQuery("#cartDetail").find("span.cart-item-name").each(function(key,str){
6262 amit.gupta 439
						blkstr.push(str);
440
					});
6303 amit.gupta 441
					label = blkstr.join(", ");
442
				} else if (label.substr(label.lastIndexOf('/') + 1).length==5 && typeof label.substr(label.lastIndexOf('/') + 1) =="number") {
443
					ev = "Category Page";
444
				} else if (label.substr(label.lastIndexOf('-') + 1).length==7  && typeof label.substr(label.lastIndexOf('-') + 1) =="number") {
445
					ev = "Product Page";
6262 amit.gupta 446
				}
6261 amit.gupta 447
				trackEventWithGA('Pickup in Store LightBox', ev, label);
6245 kshitij.so 448
			}
449
    	});
450
	});
4126 varun.gupt 451
 
5420 amit.gupta 452
	$('.common-widget-top-bar').live('click', function(e, callback){
4126 varun.gupt 453
		var isColapsed = $(this).data('is_colapsed') == true ? true : false;
454
		var widgetBox = $(this).siblings('.common-widget-content-area');
455
		var controlBox = $(this).siblings('.common-widget-control-bar');
456
		var controlBoxArrowImg = $(this).find('img');
4210 varun.gupt 457
 
4126 varun.gupt 458
		if (isColapsed)	{
459
			if(controlBox.length > 0)	{
460
				$(controlBox).slideDown('fast', function(){
5420 amit.gupta 461
					$(widgetBox).slideDown('fast', callback);
4126 varun.gupt 462
					$(controlBoxArrowImg).attr('src', '/images/IconDownArrow_UnselectedTab.png');
463
				});
464
			} else	{
465
				$(widgetBox).slideDown();
466
				$(controlBoxArrowImg).attr('src', '/images/IconDownArrow_UnselectedTab.png');
467
			}
468
		} else	{
469
			$(widgetBox).slideUp(function(){
470
				$(controlBox).slideUp('fast');
471
				$(controlBoxArrowImg).attr('src', '/images/IconRightArrow_UnselectedTab.png');
472
			});
473
		}
474
		$(this).data('is_colapsed', !isColapsed);
475
	});
476
 
477
	/**
478
	 * Update count of products checked for comparison
479
	 **/
480
	$('#myresearch input[type="checkbox"]').live('click', function(){
4798 varun.gupt 481
		updateCompareCount();
4126 varun.gupt 482
	});
483
 
484
	$("#research_compare").live('click', function(){
485
		var seldata = "";
5322 amit.gupta 486
		var prodnames = "";
4126 varun.gupt 487
		var tot = 1;
488
		var saprt = "";
489
		var par = $('#myresearch').find('input[type=checkbox]:checked');
4926 varun.gupt 490
		var haveSameProductType = true;
491
		var productType = null;
492
 
4126 varun.gupt 493
		$(par).each(function(){
4926 varun.gupt 494
 
495
			if(productType != null && productType != $(this).attr('producttype'))	{
496
				haveSameProductType = false;
497
			}
498
			productType = $(this).attr('producttype');
499
 
4126 varun.gupt 500
			if(tot == 1)	{
5358 amit.gupta 501
				prodnames += $(this).attr("title").replace(/ +/g, '-').replace(/\/+/g,'-').replace(/-+/g,'-').toLowerCase();
4126 varun.gupt 502
				seldata += "p" + tot + "=" + $(this).val();
503
			} else	{
504
				seldata += "&p" + tot + "=" + $(this).val();
5358 amit.gupta 505
				prodnames += "-vs-" + $(this).attr("title").replace(/ +/g, '-').replace(/\/+/g,'-').replace(/-+/g,'-').toLowerCase();
4126 varun.gupt 506
			}
507
			tot ++;
508
		});
4984 varun.gupt 509
 
4926 varun.gupt 510
		if(! haveSameProductType)	{
511
			alert("Only products of same category can be compared");
512
		} else if(tot > 6)	{
4126 varun.gupt 513
			alert("Can compare upto five products only.");
514
		} else if(tot > 2)	{
5552 phani.kuma 515
			window.location = "/compare-" + productType.replace(/ +/g, '-').toLowerCase() + "/" + prodnames + "?" + seldata+"&fromsrc=comparison_widget";
4126 varun.gupt 516
		} else	{
517
			alert("Please select atleast two products");
518
		}
519
	});
520
 
521
	$("#research_delete").live('click', function(){
522
		var research_tot = $("#research_total").val();
523
		var seldata = [];
524
		var tot = 0;
525
		var saprt = "";
526
		var par = $('#myresearch').find('input[type=checkbox]:checked');
527
 
528
		$(par).each(function(){
529
			seldata.unshift($(this).val());
530
			tot ++;
531
		});
532
 
533
		if(tot > 0)	{
534
			var t = (research_tot * 1) - (tot * 1);
535
			$("#research_total").val(t);
536
 
537
			jQuery.ajax({
538
				type: "GET",
539
				url: "/deletefromresearch/[" + seldata + "]?_method=delete",
540
				success: function(msg)	{
541
					jQuery.each(seldata, function(intIndex, objValue){
542
						delete_from_storage_set("resitems", objValue);
543
						$("#myresearch").find("#" + objValue).fadeOut('slow', function() {
544
							$(this).remove();
545
							if(t === 0)	{
546
								$("#research_default").css("display", "block");
547
							}
548
						});
549
					});
4984 varun.gupt 550
 
4922 varun.gupt 551
					//Updating the count
552
					$('#research_compare_count').html($('#myresearch input[type="checkbox"]:checked').length - seldata.length);
4984 varun.gupt 553
 
554
					if ($('#myresearch input[type="checkbox"]').length - seldata.length <= 0)	{
555
						$("#myresearch").children(".common-widget-top-bar").trigger('click');
556
					}
4126 varun.gupt 557
				}
558
			});
559
		} else	{
560
			alert("Please select atleast one product");
561
		}
562
	});
563
 
564
	// No uid cookie
565
	if (!$.cookie("uid"))	{
566
		// No uid in storage
567
		if (!$.Storage.get("uid"))	{
568
			if (!$.Storage.get("resitems"))	{
569
				$.Storage.set("resitems", "[]");
570
			}
571
			if (!$.Storage.get("histitems"))	{
572
				$.Storage.set("histitems", "[]");
573
			}
574
		}
575
		else	{			// uid in storage : logout
576
			$.Storage.remove("uid");
577
			$.Storage.set("resitems", "[]");
578
			$.Storage.set("histitems", "[]");
579
		}
580
		load_research_widget();
581
		load_history_widget();
582
	}
583
	else	{				// With uid cookie
584
		var cookie = $.cookie("uid");
585
		// Just logged in merge storage items
586
		if (!$.Storage.get("uid"))	{
587
			$.Storage.set("uid", cookie);
588
			merge_history_items();
589
			load_research_items();
590
		}
591
		else	{
592
			// UID changed
593
			if ( cookie != $.Storage.get("uid"))	{
594
				$.Storage.set("uid", cookie);
595
				$.Storage.set("resitems", "[]");
596
				$.Storage.set("histitems", "[]");
597
				merge_history_items();
598
				load_research_items();
599
			}
600
			else	{		// Uid is same
601
				if (!$.Storage.get("resitems"))	{
602
					$.Storage.set("resitems", "[]");
603
					load_research_items();
604
				}
605
				else	{
606
					load_research_widget();
607
				}
608
 
609
				if (!$.Storage.get("histitems"))	{
610
					$.Storage.set("histitems", "[]");
611
					merge_history_items();
612
				}
613
				else	{
614
					load_history_widget();
615
				}
616
			}
617
		}
618
	}
4798 varun.gupt 619
 
620
	function load_research_items(){
621
		jQuery.ajax({
622
			type: "GET",
623
			url: "/myresearch",
624
			cache: false,
625
			success: function(json) {
626
			    $.Storage.set("resitems", json);
627
			    load_research_widget();
628
		    }
629
		});
630
	}
631
 
632
	function load_research_widget(){
633
		var myResearchWidgetContainer = $("#myresearch");
634
 
635
		if($(myResearchWidgetContainer).length == 0) {
636
			return;
637
		}
638
		var resitems = $.Storage.get("resitems");
639
 
640
		if (resitems == "[]") {
641
			var emptyResWidgetHtml = '<table border="0" width="100%" cellspacing="1" cellpadding="0" id="research_default">\
642
		      <tbody>\
643
		        <tr><td align="center"><b>Add items to compare list</b></td></tr>\
644
		       </tbody>\
645
		      </table>';
646
			$(myResearchWidgetContainer).find(".common-widget-content-area").html(emptyResWidgetHtml);
647
			$(myResearchWidgetContainer).children(".common-widget-top-bar").trigger('click');
648
			return;
649
		}
650
		var params = "/" + resitems;
651
 
652
		jQuery.ajax({
653
			type : "GET",
654
			url : "/myresearch" + params,
655
			cache: true,
656
			success : function(html) {
657
	   		    $("#myresearch").html(html);
658
	   			updateCompareCount();
659
 
660
			    // Product Title
661
			    $("#myresearch table td div a.truncate").each(function() {
662
						$(this).truncate({addtitle : true});
663
			    });
664
 
665
			    // Product Price
666
			    $("#myresearch table td div div.price").each(function() {
667
						$(this).truncate({addtitle : true});
668
				});
669
 
670
			    // Product Details
671
			    $("#myresearch table td div div.text").each(function() {
672
						$(this).truncate( {addtitle : true});
673
				});
674
		    }
675
		});
676
	}
4126 varun.gupt 677
});