How would I add a trust Badge in the code?

Highlighted
New Member
27 0 0

I want to add a trust badge below my add to cart button, but I want it to be above my timer which is why I want to add it through the code. How would I add the trust badge through the code on the minimal standard theme?

0 Likes
Shopify Partner
28 0 0

can you please post an example of the code so we can see what you are working with.

My theme is not the same as yours so would have to see what your trying to do...


@Justin51 wrote:

I want to add a trust badge below my add to cart button, but I want it to be above my timer which is why I want to add it through the code. How would I add the trust badge through the code on the minimal standard theme?


 

0 Likes
Shopify Partner
28 0 0

You can add a trust badge by including

<img src="YourImagefile.jpg" style="Your Styles width + height etc">

here is an example of an image I have included:

 

<img src="https://bit.ly/2YeafnJ" class="zoomInz artzImg"
          alt="https://bit.ly/2JYFqk3">

 

html image tags should always have an alt"" attribute aswell in the case that the browser cannot load the image

Tip: You can use Bitly URL shortener to keep your code looking cleaner, especially when you have extra long URLs. for images or links.

0 Likes
New Member
27 0 0

Im on the Minimal standard theme. I'm not sure what part of my code you want me to show you a picture of.


@ElysiumFields wrote:

You can add a trust badge by including

<img src="YourImagefile.jpg" style="Your Styles width + height etc">

here is an example of an image I have included:

 

<img src="https://bit.ly/2YeafnJ" class="zoomInz artzImg"
          alt="https://bit.ly/2JYFqk3">

 

html image tags should always have an alt"" attribute aswell in the case that the browser cannot load the image

Tip: You can use Bitly URL shortener to keep your code looking cleaner, especially when you have extra long URLs. for images or links.


 

0 Likes
Shopify Partner
28 0 0

You can paste code snippets in here I think...

 

Are you trying to add a trust badge in the cart? if so it will probably be in cart.liquid or cart template.

you need to figure out which blocks of code represent differnt things on the page.

ie buy now button, add to wishlist button.  product image etc...

 

<img></img> is a block element, {% Comment %} sections are blocks. < a href="somelink"></a> is a block.. etc etc.

 

Duplicate your theme. Then paste this in to one of your cart files;

<section style="width:45px;height:45px;background:orange;"></section>

save the file and reload the shop cart page to see where the orange thing lands on your page...

keep moving it around until it is under you Buy Now Button.

then change it to an image of a trust logo.

 

to center the trust logo under the button use

         Position:relative;

         left :50%;

         transform:translateX(-50%);

 

 

0 Likes
Shopify Partner
28 0 0

Use right click and inspect elecment to see which part of code your looking for.

if you right click the Buy It Now button,

It should highlight this section of code

in the developer tools

then right click again and select copy inner or outer html..

0 Likes