Make a picture clickable to phone a number

Solved
Highlighted
Tourist
4 0 1

I found a thread that puts in a phone number that when clicked,  will phone the number directly:

the code is:

 

<a href="tel:18475555555">1-847-555-5555</a>

 

I have used this on some of my pages and it does work. 

 

I would like to insert a picture of a telephone (icon) and somehow attach the code to it so that when a customer clicks the phone icon, it will make the phone call.    this is not the same as attaching a link to the picture (I don' think...)

 

any ideas out there?  Thanks,  Roger. 

 

 

0 Likes
Highlighted

Success.

Shopify Partner
87 29 20

Hey Roger, images can be linked just like text! Just replace the text with an image tag. For example,

<a href="tel:18475555555">1-847-555-5555</a>

becomes

<a href="tel:18475555555">
  <img src="https://www.website.com/path/to/icon" />
</a>

Is your store fast enough? Compare your store's speed against hundreds of others for free with our benchmarker - https://www.rvere.com/
0 Likes
Highlighted
Tourist
4 0 1

Thx!  it seems to work.  I haven't spent a lot of time with it yet.  But first indications are that it will do the job!  

Sincerly, Roger. 

1 Like
Highlighted
Tourist
4 0 1

As one additional question:  is there a similar way to do this for emails? (I don't know any of the syntax)  ie.  provide an icon or  written text email  and have it setup so that when a customer clicks on it, it will automatically take them to their email, with the address filled in for them.  (so many other programs do his automatically, when they recogized that you have typed in an email).  Thx.  Roger. 

0 Likes
Highlighted

Success.

Shopify Partner
87 29 20

Yup! They're called mailto links, here's a guide on that https://css-tricks.com/snippets/html/mailto-links/

Is your store fast enough? Compare your store's speed against hundreds of others for free with our benchmarker - https://www.rvere.com/
0 Likes
Tourist
4 0 1

Looks easy enough!  thx for the link to the info.  Sincerely,  Roger. 

0 Likes