Welcome, Guest
Username: Password: Remember me
Use this Category for your support questions about Responsive Joomla Virtuemart Template - LightMart (SKU# FLEX-00012)

TOPIC: Tabs and menu not working

Tabs and menu not working 9 years 9 months ago #10171

hello, I am Ver.1.3 lightmart template, but I need to remove the module cart, when I disable, the tabs of the products simply do not work, and the main menu is a cut on each side, the error in firebug is:

TypeError: vmcartck.offset (...) is null


vmcartck.top vmcartck.offset = () top.;

What could be happening?
Attachments:
The topic has been locked.

Tabs and menu not working 9 years 9 months ago #10175

Hi,

Because "Cart Module" must be presented to run the "animation" in the product details page.
If you want to unpublished the cart module, then you need some coding modifications in the product details page:

Don't worry, it is easy. Follow my steps:

1- open this PHP file:
/templates/flexible_lightmart/html/com_virtuemart/productdetails/default.php

2- Look for these lines:
if (!empty($this->product->images[0]->file_url_thumb)) {
$document->addScriptDeclaration("
	jQuery(document).ready(function($) {
		var vmcartck = $('.vmCartModule');
	vmcartck.top = vmcartck.offset().top;
	vmcartck.left = vmcartck.offset().left;
 
	$('input.addtocart-button').click(function() {
			var el = $(this);
			var imgtodrag = $('div.main-image img.product-image');
			if (!imgtodrag.length) {
				elparent = el.parent();
				while (!elparent.hasClass('spacer')) {
					elparent = elparent.parent();
				}					
			}
			if (imgtodrag.length) {
				var imgclone = imgtodrag.clone()
					.offset({ top: imgtodrag.offset().top, left: imgtodrag.offset().left })
					.css({'opacity': '0.7', 'position': 'absolute' , 'height':'auto' , 'width': '300px','z-index': '1000'})
					.appendTo($('body'))
					.animate({
						'top': vmcartck.top+50,
						'left': vmcartck.left+150,
						'width':150,
						'height':150
					},1800, 'swing');
				imgclone.animate({
					'width': 0,
					'height': 0
				});
			}
	});		
	});
");
}

3- remove those lines completely.

You won't see the error message anymore, and everything will work as expected (even though you unpublished the Cart Module)

Regards,
Support
The topic has been locked.

Tabs and menu not working 9 years 9 months ago #10180

thank you :) everything is running now :)
The topic has been locked.

Tabs and menu not working 9 years 9 months ago #10189

Sure, your welcome.

Case solved. Topic is closed.

If you like LightMart and satisfied with the support you have received, please "write a review" on:
www.flexiblewebdesign.com/Joomla-Virtuemart-Templates/LightMart

Rate LightMart and write a couple of sentences to share your experience with the support team.
It won't take more than 2 minutes from you but it is extremely important for us.

Thanks in advance!

Regards,
Support
The topic has been locked.
Time to create page: 0.102 seconds

MaterialMart

for Virtuemart 3

Google's Material Design has finally arrived to Virtuemart

Virtumart Template - MaterialMart Virtumart Template - CleanMart Virtumart Template - CleanMart Virtumart Template - CleanMart

Fully responsive!

Buy Now   |   Live Demo