[Skip to main content](#vessel-content)

#   Add to cart button in product view not right

##

- **[noaboa](/forum/user/48928-noaboa "View noaboa's Profile")**
- [![noaboa's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/48928-noaboa "View noaboa's Profile") Topic Author
- [ Offline](/forum/user/48928-noaboa)

Less More

- Posts: 18
- Thank you received: 0
-
-

9 years 6 months ago [\#268172](#268172) by [noaboa](/forum/user/48928-noaboa "View noaboa's Profile")  *[Add to cart button in product view not right](/forum/26-product-category-display/889962-add-to-cart-button-in-product-view-not-right#268172 "Hello,  So the &quot;add to cart&quot; button is alligned in the center under the options field. When there is no chracteristic choosen it aligns correctly. The margin is the to auto but when i change the margin the button also aligns left in the product listing. How can I fix that?  Thanks :)")* was created by *[noaboa](/forum/user/48928-noaboa "View noaboa's Profile")*

Hello,

So the "add to cart" button is alligned in the center under the options field. When there is no chracteristic choosen it aligns correctly.
The margin is the to auto but when i change the margin the button also aligns left in the product listing.
How can I fix that?

Thanks ![:)](/media/kunena/emoticons/3.png ":)")

- [ ![zoom.png](/forum/attachment/37828) ](/forum/attachment/37828 "zoom.png") [ ](/forum/attachment/37828?download=1 "zoom.png")
- [ ![addtocartalign.png](/forum/attachment/37829) ](/forum/attachment/37829 "...ocartalign.png") [ ](/forum/attachment/37829?download=1 "...ocartalign.png")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI2LXByb2R1Y3QtY2F0ZWdvcnktZGlzcGxheS84ODk5NjItYWRkLXRvLWNhcnQtYnV0dG9uLWluLXByb2R1Y3Qtdmlldy1ub3QtcmlnaHQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Philip](/forum/user/34318-philip "View Philip's Profile")**
- [![Philip's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/34318-philip "View Philip's Profile")
- [ Offline](/forum/user/34318-philip)

Less More

- Posts: 4820
- Thank you received: 652
-
-

9 years 6 months ago -  9 years 6 months ago [\#268218](#268218) by [Philip](/forum/user/34318-philip "View Philip's Profile")  Replied by *[Philip](/forum/user/34318-philip "View Philip's Profile")* on topic *[Add to cart button in product view not right](/forum/26-product-category-display/889962-add-to-cart-button-in-product-view-not-right#268218 "Hello,  So the &quot;add to cart&quot; button is alligned in the center under the options field. When there is no chracteristic choosen it aligns correctly. The margin is the to auto but when i change the margin the button also aligns left in the product listing. How can I fix that?  Thanks :)")*

Hello,

Sorry but I'm not sure to understand your issue, can you explain more precisely your needs or your issue ?
You want **modify your Css** but you don't succeed ? Or there something that **don't fit your display needs** ?

In order to better answer you can you provide and **Url link** to better understand your Css files.

Awaiting news from you.

Regards

Last edit: 9 years 6 months ago by [Philip](/forum/user/34318-philip "View Philip's Profile").

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI2LXByb2R1Y3QtY2F0ZWdvcnktZGlzcGxheS84ODk5NjItYWRkLXRvLWNhcnQtYnV0dG9uLWluLXByb2R1Y3Qtdmlldy1ub3QtcmlnaHQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[noaboa](/forum/user/48928-noaboa "View noaboa's Profile")**
- [![noaboa's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/48928-noaboa "View noaboa's Profile") Topic Author
- [ Offline](/forum/user/48928-noaboa)

Less More

- Posts: 18
- Thank you received: 0
-
-

9 years 6 months ago [\#268263](#268263) by [noaboa](/forum/user/48928-noaboa "View noaboa's Profile")  Replied by *[noaboa](/forum/user/48928-noaboa "View noaboa's Profile")* on topic *[Add to cart button in product view not right](/forum/26-product-category-display/889962-add-to-cart-button-in-product-view-not-right#268263 "Hello,  So the &quot;add to cart&quot; button is alligned in the center under the options field. When there is no chracteristic choosen it aligns correctly. The margin is the to auto but when i change the margin the button also aligns left in the product listing. How can I fix that?  Thanks :)")*

Hi Philip

The "add to cart" buttom will center itself under the selection field when a characteritic is choosen in the backend . like in the picture.
when there is no characteristics choosen it aligns left under the price and description.

Here's the link: [ josephinesjewellery.ch.dedi1028.your-ser...e/index.php/braclets](http://josephinesjewellery.ch.dedi1028.your-server.de/index.php/braclets)

Thnaks in advance.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI2LXByb2R1Y3QtY2F0ZWdvcnktZGlzcGxheS84ODk5NjItYWRkLXRvLWNhcnQtYnV0dG9uLWluLXByb2R1Y3Qtdmlldy1ub3QtcmlnaHQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[kenny.kang](/forum/user/39538-kenny-kang "View kenny.kang's Profile")**
- [![kenny.kang's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/39538-kenny-kang "View kenny.kang's Profile")
- [ Offline](/forum/user/39538-kenny-kang)

Less More

- Posts: 22
- Thank you received: 0
-
-

9 years 6 months ago [\#268283](#268283) by [kenny.kang](/forum/user/39538-kenny-kang "View kenny.kang's Profile")  Replied by *[kenny.kang](/forum/user/39538-kenny-kang "View kenny.kang's Profile")* on topic *[Add to cart button in product view not right](/forum/26-product-category-display/889962-add-to-cart-button-in-product-view-not-right#268283 "Hello,  So the &quot;add to cart&quot; button is alligned in the center under the options field. When there is no chracteristic choosen it aligns correctly. The margin is the to auto but when i change the margin the button also aligns left in the product listing. How can I fix that?  Thanks :)")*

I am the same problem after upgrade up 3.0.1

[ hikashop.bikehome.com.tw/display-all-acc...ies/parts/category/c](http://hikashop.bikehome.com.tw/display-all-accessories/parts/category/c)

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI2LXByb2R1Y3QtY2F0ZWdvcnktZGlzcGxheS84ODk5NjItYWRkLXRvLWNhcnQtYnV0dG9uLWluLXByb2R1Y3Qtdmlldy1ub3QtcmlnaHQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Jerome](/forum/user/80-jerome "View Jerome's Profile")**
- [![Jerome's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar80.png)](/forum/user/80-jerome "View Jerome's Profile")
- [ Offline](/forum/user/80-jerome)
- HikaShop core developer

Less More

- Posts: 26395
- Thank you received: 4077
-
- [](http://obsi.dev)
-

9 years 6 months ago [\#268274](#268274) by [Jerome](/forum/user/80-jerome "View Jerome's Profile")  Replied by *[Jerome](/forum/user/80-jerome "View Jerome's Profile")* on topic *[Add to cart button in product view not right](/forum/26-product-category-display/889962-add-to-cart-button-in-product-view-not-right#268274 "Hello,  So the &quot;add to cart&quot; button is alligned in the center under the options field. When there is no chracteristic choosen it aligns correctly. The margin is the to auto but when i change the margin the button also aligns left in the product listing. How can I fix that?  Thanks :)")*

Hello,

I'm sorry but your issue is CSS related and the CSS is coming from your template.
So I'm afraid that outside the limit of our support.
But we do have a documentation page which explain basis of CSS edition :
[ www.hikashop.com/support/documentation/1...the-display.html#css](https://www.hikashop.com/support/documentation/153-customize-the-display.html#css)

Regards,

---

Jerome - Obsidev.com
HikaMarket &amp; HikaSerial developer / HikaShop core dev team.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI2LXByb2R1Y3QtY2F0ZWdvcnktZGlzcGxheS84ODk5NjItYWRkLXRvLWNhcnQtYnV0dG9uLWluLXByb2R1Y3Qtdmlldy1ub3QtcmlnaHQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[noaboa](/forum/user/48928-noaboa "View noaboa's Profile")**
- [![noaboa's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/48928-noaboa "View noaboa's Profile") Topic Author
- [ Offline](/forum/user/48928-noaboa)

Less More

- Posts: 18
- Thank you received: 0
-
-

9 years 6 months ago [\#268349](#268349) by [noaboa](/forum/user/48928-noaboa "View noaboa's Profile")  Replied by *[noaboa](/forum/user/48928-noaboa "View noaboa's Profile")* on topic *[Add to cart button in product view not right](/forum/26-product-category-display/889962-add-to-cart-button-in-product-view-not-right#268349 "Hello,  So the &quot;add to cart&quot; button is alligned in the center under the options field. When there is no chracteristic choosen it aligns correctly. The margin is the to auto but when i change the margin the button also aligns left in the product listing. How can I fix that?  Thanks :)")*

but the problem is, that for both buttons there are only one php file. if i edit the table and add the class or id to it it will apear on the product listing and the productpage. do you understand my problem? I can't change the css beceause if i do it will be applied on both buttons since i cant give both tables a diffrent id or class...

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI2LXByb2R1Y3QtY2F0ZWdvcnktZGlzcGxheS84ODk5NjItYWRkLXRvLWNhcnQtYnV0dG9uLWluLXByb2R1Y3Qtdmlldy1ub3QtcmlnaHQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Away](/forum/user/63-nicolas)

Less More

- Posts: 86363
- Thank you received: 14297
-
-

9 years 6 months ago -  9 years 6 months ago [\#268363](#268363) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Add to cart button in product view not right](/forum/26-product-category-display/889962-add-to-cart-button-in-product-view-not-right#268363 "Hello,  So the &quot;add to cart&quot; button is alligned in the center under the options field. When there is no chracteristic choosen it aligns correctly. The margin is the to auto but when i change the margin the button also aligns left in the product listing. How can I fix that?  Thanks :)")*

Hi,

I'm sorry but you're wrong.
You just have to write the correct CSS so that it applies only to one of both.
For example:
.hikashop_products_listing .hikashop_cart_input_button{
color : green;
}
will only apply on the listing, and:
.hikashop_product_page .hikashop_cart_input_button{
color : blue;
}
will only apply on the product page.
Please understand that this is a user support forum for HikaShop.
We can't provide courses on CSS coding. If you need to learn about CSS coding, I'd recommend some online tutorials:
[ css-tricks.com/specifics-on-css-specificity/](https://css-tricks.com/specifics-on-css-specificity/)

Last edit: 9 years 6 months ago by [nicolas](/forum/user/63-nicolas "View nicolas's Profile").

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI2LXByb2R1Y3QtY2F0ZWdvcnktZGlzcGxheS84ODk5NjItYWRkLXRvLWNhcnQtYnV0dG9uLWluLXByb2R1Y3Qtdmlldy1ub3QtcmlnaHQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

Board Categories HikaShop Install &amp; Update Product &amp; Category Display Content Creation Sales and Orders Orders management Reports &amp; Statistics Customers Checkout Payment Methods Shipping Methods Import &amp; Export (CSV, XLS…) Specific Features Affilation Taxes Wishlist Vote Carousel &amp; Slider Mass Actions Filters &amp; Search Discount &amp; Coupon Feature Request Integrations Showcase General Talk about HikaShop Development HikaShop 3.0 Beta Translation Commercial Jobs HikaShop Components HikaMarket Market: Feature requests Market: How to? Market: Bug Report HikaSerial General talk about HikaSerial Serial: Bug Report Serial: How to? Support en Français de HikaSerial (French Support) HikaSubscription HikaAuction Auction: Feature requests Auction: How to? Auction: Bug report Hikashop around the world Support en Français (French Support) Russian FAQ. Курс выживания с Hikashop. Частые вопросы и о Расширения Hikashop Наши сайты на Hikashop 日本語版サポート(Japanese Support) Thai German Archives Bug Report How to?

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.060 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)
