![]() |
JQuery Mobile sending me crazy
Hi all,
I've applied JQuery Mobile to my Virtuemart site, now trying to edit. My add to cart button should fire a Virtuemart AJAX function called handleAddToCart however JQuery Mobile AJAX linking disables this. I need away to disable AJAX Mobile on the add to cart link AND run the original function handleAddToCart. I'm currently using preventDefault() which successfully prevents JQuery Mobile from doing a AJAX link but it also doesn't fire the original handleAddToCart function. Spent hours on this, if anyone can see how to fix I will worship you!! This JQuery successfully stops JQuery mobile from hijacking the link but it wont start handleAddToCart function! Code:
<script>Code:
<form action="<?php echo $mm_action_url ?>index.php" method="post" name="addtocart" id="addtocart<?php echo $i ?>" class="addtocart_form" <?php if( $this->get_cfg( 'useAjaxCartActions', 1 ) && !$notify ) { echo 'onsubmit="handleAddToCart( this.id );return false;"'; } ?>> |
Hi,
Maybe it would be simpler to ask how I can disable Mobile JQuery Only in DIV tags and leave other ajax running. |
Does div.bsubmitcart binding to click event have to be inside the form.addtocart_form binding? Could it be moved out from red to blue, like below?
Code:
$('[data-role="page"]').bind('pageinit', function () { |
| All times are GMT +1. The time now is 11:44 PM. |
Powered by vBulletin®
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.