-
AuthorPosts
-
Ch1vpH Friend
Ch1vpH
- Join date:
- February 2016
- Posts:
- 299
- Downloads:
- 21
- Uploads:
- 128
- Thanks:
- 29
- Thanked:
- 1 times in 1 posts
June 17, 2017 at 10:51 am #1042443Hi there,
Is there a way to make the ‘Head Cart’ Button click through directly to ‘My Cart’ INSTEAD of the off-canvas menu appearing on the left and then having to click ‘show cart’ again to get to the My Cart Page.
Thanks,
site is: http://ch1vph.xyz/ri2k
Saguaros ModeratorSaguaros
- Join date:
- September 2014
- Posts:
- 31405
- Downloads:
- 237
- Uploads:
- 471
- Thanks:
- 845
- Thanked:
- 5346 times in 4964 posts
June 19, 2017 at 9:33 am #1042735Hi,
In that ‘head-cart’ position, we use VM Shopping Cart module there – it’s heavy customization on javascript on this module to have feature as demo site so if you want to customize it again, pls edit this file: [root]/templates/ja_brickstore/html/mod_virtuemart_cart/default.php
Ch1vpH FriendCh1vpH
- Join date:
- February 2016
- Posts:
- 299
- Downloads:
- 21
- Uploads:
- 128
- Thanks:
- 29
- Thanked:
- 1 times in 1 posts
June 19, 2017 at 11:15 am #1042779Hi there,
Thanks for letting me know the file….but what should I be looking for, in order to just have the wording ‘My Cart’ click through as a link?
Thanks.
Ps: Is there a way just to have the ‘My Cart’ text click through as a menu item (in the Head Cart position) and that way I can create a link the my cart page
Saguaros ModeratorSaguaros
- Join date:
- September 2014
- Posts:
- 31405
- Downloads:
- 237
- Uploads:
- 471
- Thanks:
- 845
- Thanked:
- 5346 times in 4964 posts
June 20, 2017 at 9:14 am #1042983You can try this way if you don’t want to customize above file:
- Copy the core file of this module in this directory: [root]/modules/mod_virtuemart_cart/tmpl/default.php
- Paste into this folder: [root]/templates/ja_brickstore/html/mod_virtuemart_cart/ and rename it to another name instead of ‘default.php’. For example: name it ‘defaule-copy.php’
- Go to backend settings of this VM Shopping Cart module > Advanced tab and select ‘default-copy’ as alternative layout for this module (it will load the new file you added)
On frontend you will see it load various elements of this module, you can edit ‘default-copy.php’ file above to show what you wish but keep the link of show your shopping cart (this module has this link already, you don’t need to add).
Hope this helps.
Ch1vpH FriendCh1vpH
- Join date:
- February 2016
- Posts:
- 299
- Downloads:
- 21
- Uploads:
- 128
- Thanks:
- 29
- Thanked:
- 1 times in 1 posts
June 21, 2017 at 7:24 pm #1043317Hi there,
So I’m nearly there…I basically used a mix of your two methods above & in the end I took the /modules/mod_virtuemart_cart/tmpl/default.php and put it into directly into the original brickstore template default.php (minus the ‘off canvas’ cart effect) this way I was able to keep the module ‘button’ looking the same as it was – see attached image
I’m now at the stage where I need some help to find a way to either add a direct http link to the ‘Cart Button’ so it will go directly to the ‘My Cart Page’ or I need a way to add the code I have copied (below) from the module default.php to into the currently live .php file
Because if I add the following code, a separate working ‘Show Cart’ link appears (although not in the correct position or css as the original cart module ) see 2nd image
<div class="show_cart"> <?php if ($data->totalProduct) echo $data->cart_show; ?> </div>
- This reply was modified 7 years, 6 months ago by Ch1vpH.
-
Saguaros Moderator
Saguaros
- Join date:
- September 2014
- Posts:
- 31405
- Downloads:
- 237
- Uploads:
- 471
- Thanks:
- 845
- Thanked:
- 5346 times in 4964 posts
June 22, 2017 at 3:51 am #1043393This shopping cart module helps to show the quick view of added items in cart: number of item, price, total price, etc… normally, when clicking the cart icon it will show these info in dropdown or in this template specific, it shows in off-canvas panel.
So if you want to use this module, you have to customize much as I mentioned above: PHP code and style for it.
Another option is you create another custom module and add to current position. Inside this module, you manually add link to shopping cart, this link is from the Shopping Cart menu item on your site.
Ch1vpH FriendCh1vpH
- Join date:
- February 2016
- Posts:
- 299
- Downloads:
- 21
- Uploads:
- 128
- Thanks:
- 29
- Thanked:
- 1 times in 1 posts
June 22, 2017 at 6:24 pm #1043579If anyone else wants to have the Cart click straight to the basket page with having to go through the offcanvas side bar see below:
Just copy the code from: mod_virtuemart_cart/tmpl/default.php & paste it into the: ja_brickstore/html/mod_virtuemart_cart.default.php
Then remove all the off canvas code & the off canvas references in the ‘button’ class at the top of page and add a http link<a href="yourbasket">and close off the code withbasically copy as below and paste under
<button class="btn-cart"><a href="http://yourbasket-link"> <i class="ion-android-cart"></i> <span><?php echo JText::_( 'TPL_MYCART' ); ?></span> <sup class="total-product"><?php echo $data->totalProduct ?></sup> <span class="total"> / <?php if ($data->totalProduct and $show_price and $currencyDisplay->_priceConfig['salesPrice'][0]) { echo $data->billTotal; } else { echo '0.00'; } ?> </span> </a> </button>
Saguaros ModeratorSaguaros
- Join date:
- September 2014
- Posts:
- 31405
- Downloads:
- 237
- Uploads:
- 471
- Thanks:
- 845
- Thanked:
- 5346 times in 4964 posts
June 23, 2017 at 4:27 am #1043709Is that ok now?
Ch1vpH FriendCh1vpH
- Join date:
- February 2016
- Posts:
- 299
- Downloads:
- 21
- Uploads:
- 128
- Thanks:
- 29
- Thanked:
- 1 times in 1 posts
July 10, 2017 at 9:56 pm #1047407Yes thanks just glad I left this post as I had to re-do this process after upgrading!!
Just to go over what I mentioned above if anyone else wants to bypass the off canvas checkout route just copy the code below into the file: ja_brickstore/html/mod_virtuemart_cart.default.php
<?php // no direct access defined('_JEXEC') or die('Restricted access'); //dump ($cart,'mod cart'); // Ajax is displayed in vm_cart_products // ALL THE DISPLAY IS Done by Ajax using "hiddencontainer" ?> <!-- Virtuemart 2 Ajax Card --> <button class="btn-cart"><a href="https://YOURSITE.COM/basket-link"> <i class="ion-android-cart"></i> <span><?php echo JText::_( 'TPL_MYCART' ); ?></span> <sup class="total-product"><?php echo $data->totalProduct ?></sup> <span class="total"> / <?php if ($data->totalProduct and $show_price and $currencyDisplay->_priceConfig['salesPrice'][0]) { echo $data->billTotal; } else { echo '0.00'; } ?> </span> </a> </button>
- This reply was modified 7 years, 5 months ago by Ch1vpH.
-
AuthorPosts
Viewing 9 posts - 1 through 9 (of 9 total)This topic contains 8 replies, has 2 voices, and was last updated by Ch1vpH 7 years, 5 months ago.
We moved to new unified forum. Please post all new support queries in our New Forum
Jump to forum