- Posts: 73
- Thank you received: 2
Modify 'Add to cart' button
10 years 10 months ago #221687
by mypetfly
Modify 'Add to cart' button was created by mypetfly
-- HikaShop version -- : 2.6.0
-- Joomla version -- : 3.4.5
-- PHP version -- : 5.3.29
-- Browser(s) name and version -- : Firefox 41.0.2
-- Error-message(debug-mod must be tuned on) -- : Need to modify "Add to cart" button
Hello,
I would like to modify 'add to cart' button (for hikashop module) to look it like in the attachment. So, I need to put the cart logo to this button.
I've tried to do it using file in /views/product folder, but seems that it is not possible because all I can see is:
<!-- ADD TO CART BUTTON AREA -->
<?php
if($this->params->get('add_to_cart') || $this->params->get('add_to_wishlist')){
$this->setLayout('add_to_cart_listing');
echo $this->loadTemplate();
}?>
<!-- EO ADD TO CART BUTTON AREA -->
I've found source code for this button at administrator/components/com_hikashop/helpers/cart.php, but all my changes will be overwritten after hikashop update.
Also I've tried to insert it using :before css style for this button in order to set icon via css, but without success.
Is any good solution for this?
-- Joomla version -- : 3.4.5
-- PHP version -- : 5.3.29
-- Browser(s) name and version -- : Firefox 41.0.2
-- Error-message(debug-mod must be tuned on) -- : Need to modify "Add to cart" button
Hello,
I would like to modify 'add to cart' button (for hikashop module) to look it like in the attachment. So, I need to put the cart logo to this button.
I've tried to do it using file in /views/product folder, but seems that it is not possible because all I can see is:
<!-- ADD TO CART BUTTON AREA -->
<?php
if($this->params->get('add_to_cart') || $this->params->get('add_to_wishlist')){
$this->setLayout('add_to_cart_listing');
echo $this->loadTemplate();
}?>
<!-- EO ADD TO CART BUTTON AREA -->
I've found source code for this button at administrator/components/com_hikashop/helpers/cart.php, but all my changes will be overwritten after hikashop update.
Also I've tried to insert it using :before css style for this button in order to set icon via css, but without success.
Is any good solution for this?
Please Log in or Create an account to join the conversation.
10 years 10 months ago - 10 years 10 months ago #221726
by mypetfly
Replied by mypetfly on topic Modify 'Add to cart' button
Actually I think the simplest way to add such icon is just set background for <input>. I was just thinking about using this icon as <i> element and 'font-awesome' font.
Will try to it tis way. No need to write a reply.
Will try to it tis way. No need to write a reply.
Last edit: 10 years 10 months ago by mypetfly.
Please Log in or Create an account to join the conversation.
10 years 10 months ago #221702
by nicolas
Replied by nicolas on topic Modify 'Add to cart' button
Hi,
You can do that with CSS yes:
www.hikashop.com/forum/4-how-to/47121-cu...-to-cart-button.html
hikashop.com/forum/4-how-to/83718-change...button-to-image.html
You can do that with CSS yes:
www.hikashop.com/forum/4-how-to/47121-cu...-to-cart-button.html
hikashop.com/forum/4-how-to/83718-change...button-to-image.html
Please Log in or Create an account to join the conversation.
Time to create page: 0.221 seconds