Skip to main content

Cart module icon display

More
7 years 1 week ago #311413 by NicoW
-- url of the page with the problem -- : www.norahlux.red

Hi,

I added :
Code:
if($this->cart_type == 'wishlist'){ echo '<i class="far fa-heart" style="font-size:24px;color:white"></i>'; } if($this->cart_type == 'cart'){ echo '<i class="fas fa-shopping-basket" style="font-size:24px;color:white"></i>'; }
to view > product > cart and it produces the wanted outcome.

I have added some code to produce item numers in circles, and when a product is added to wishlist it works fine.
Now I have 2 issues still:
1 how can I make the circles only visible when items are added?
2 When i add items to cart, it will produce a second basket on top of the first one, what am i missing?
(3th question, can the icons become a link same as the items number link (to wishlist and basket?)

Code added to css:
Code:
.topbar-section >div .hikashop_cart_module{ position: absolute; top: 1px; right: 60px; z-index : 0; } .topbar-section >div .hikashop_wishlist_module{ position: absolute; top: 1px; right: 110px; z-index : 0; } .topbar-section >div .hikashop_cart{ position: absolute; top: -10px; right: -10px; border:1px solid white; background-color:#fa8080; height:18px; border-radius:50%; -moz-border-radius:50%; -webkit-border-radius:50%; width:18px; text-align: center; line-height: 1.1; z-index : 1;

Please Log in or Create an account to join the conversation.

More
7 years 5 days ago - 7 years 5 days ago #311451 by Philip
Replied by Philip on topic Cart module icon display
Hello,

"1 how can I make the circles only visible when items are added?"

On your website url, I can see that when there is no products, you have a little red circle, then to answer your question you have to add css command only on the cart quantity input, for this get the html class on the quantity :
- Point your element, click-right, select inspect (or inspector or inspector tool) , a new window will be display and that you will see html and can see class, here the quantity.

"2 When i add items to cart, it will produce a second basket on top of the first one, what am i missing?"

Are you sure that you don't add more than 2 times your cart icon ? I advice you to analyze your code because so far your condition seems good.

"3th question, can the icons become a link same as the items number link (to wishlist and basket?"

Sorry, but we don't understand your question, can you precise it, and use some concrete examples ?

Awaiting news from you.
Regards
Last edit: 7 years 5 days ago by Philip.

Please Log in or Create an account to join the conversation.

Time to create page: 0.201 seconds
Powered by Kunena Forum