Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
Locked
0

Add a shopping cart icon

Explorer ,
May 09, 2018 May 09, 2018

Is there a way to add a shopping cart icon instead of having the plain text "view cart"?

TOPICS
eCommerce
1.1K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Participant , May 10, 2018 May 10, 2018

Assuming your in the Shopping Cart Summary layout you can use this documentation to help - Shopping cart summary | Business Catalyst Developers

You can create the <a> tag and use {{cartUrl}} , then add what ever you like for your icon.

If you are not in the cart summary layout, you can manually create a link to the cart (OrderRetrievev2.aspx).

Don't forget to check out the code and see what BC renders out by default.

ie. /OrderRetrievev2.aspx?CatalogueID=[THE CURRENT CATALOGUE ID]

Translate
Participant ,
May 10, 2018 May 10, 2018

Assuming your in the Shopping Cart Summary layout you can use this documentation to help - Shopping cart summary | Business Catalyst Developers

You can create the <a> tag and use {{cartUrl}} , then add what ever you like for your icon.

If you are not in the cart summary layout, you can manually create a link to the cart (OrderRetrievev2.aspx).

Don't forget to check out the code and see what BC renders out by default.

ie. /OrderRetrievev2.aspx?CatalogueID=[THE CURRENT CATALOGUE ID]

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
May 12, 2018 May 12, 2018

Thanks James,

I did the manual link, pages were created in Muse. Now, I am trying to get the {tag_itemCount}to show on (inside)the icon, I have tried adding it as <a> and several other ways, but its not rendering. heres the code that displays the icon <a href="http://www.raggssupply.com/OrderRetrievev2.aspx?" target="_self"><img alt="" src="/images/shopping bag_New.png" style="border: 0px;" /></a>

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Participant ,
May 13, 2018 May 13, 2018
LATEST

There are many ways to have a numeric indicator layed over an icon, Font Awesome can do this within their own library: https://fontawesome.com/how-to-use/svg-with-js#layering

However if you want to code it manually you need to wrap the icon and the indicator in an element that is postion:relative and then position the numeric indicator with position: absolute.

For example see the code on this page: Inland Petroleum - Home

With this in the header:

That should get you started.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines