Subversion Repositories SmartDukaan

Rev

Rev 4276 | Rev 4740 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 4276 Rev 4372
Line 26... Line 26...
26
$(function() {
26
$(function() {
27
	  $('.add-to-cart-icon').live('click', function() {
27
	  $('.add-to-cart-icon').live('click', function() {
28
	    var items = this.id;
28
	    var items = this.id;
29
	    var itemsarray = items.split('-');
29
	    var itemsarray = items.split('-');
30
	    addToCart(itemsarray[1], itemsarray[0]);
30
	    addToCart(itemsarray[1], itemsarray[0]);
-
 
31
	    trackEventWithGA('Home Page', 'Add to Cart Click', '');
31
	    return false;
32
	    return false;
32
	  });
33
	  });
33
	  
34
	  
34
	$("a.addtocart").live('click', function() {
35
	$("a.addtocart").live('click', function() {
35
		var catalogid = $(this).attr('catalogid');
36
		var catalogid = $(this).attr('catalogid');
Line 42... Line 43...
42
		});
43
		});
43
		
44
		
44
		radBtn += '<div class="clearBoth"></div>';
45
		radBtn += '<div class="clearBoth"></div>';
45
		$(".colorSelLightBoxColor .content").html(radBtn);
46
		$(".colorSelLightBoxColor .content").html(radBtn);
46
 
47
 
-
 
48
		$.fn.colorbox({
-
 
49
			inline:true, 
47
		$.fn.colorbox({inline:true, href:".colorSelLightBoxColor", open:true, onComplete:function(){
50
			href:".colorSelLightBoxColor", 
-
 
51
			open:true, 
-
 
52
			onComplete:function(){
48
			var posLeft = (document.documentElement.clientWidth / 2) - (parseInt($('#colorbox').css('width')) / 2);
53
				var posLeft = (document.documentElement.clientWidth / 2) - (parseInt($('#colorbox').css('width')) / 2);
49
			var posTop = (document.documentElement.clientHeight / 2) - (parseInt($('#colorbox').css('height')) / 2);
54
				var posTop = (document.documentElement.clientHeight / 2) - (parseInt($('#colorbox').css('height')) / 2);
50
 
55
 
51
			$('#colorbox').css('top', posTop);
56
				$('#colorbox').css('top', posTop);
52
			$('#colorbox').css('left', posLeft);
57
				$('#colorbox').css('left', posLeft);
-
 
58
			    trackEventWithGA('Home Page', 'Add to Cart Click', '');
-
 
59
			}
53
		}});
60
		});
54
	});
61
	});
55
	
62
	
56
	
63
	
57
	$('#notify').live('click', function() {
64
	$('#notify').live('click', function() {
58
		emailExp = /^[\w\-\.\+]+\@[a-zA-Z0-9\.\-]+\.[a-zA-z0-9]{2,4}$/;
65
		emailExp = /^[\w\-\.\+]+\@[a-zA-Z0-9\.\-]+\.[a-zA-z0-9]{2,4}$/;