• 0
Sign in to follow this  
Followers 0

Changing header image so it dials phone number when clicked?


Question

Posted · Report post

Hello everyone!

I have searched the forums for the answer to this, and cannot find the answer.

My client's site is here. http://diamond-jim.com/

Currently when you click the banner at the top, it just takes you back to the home page.

We would like for when you click the banner for it to call a number, since a majority of the visitors to the site are on mobile. I know this is possible, and have the code to do it, but I dont know where to put the code.

I am aware of where the custom code input is for the childtheme in Pagelines, but do not know how to properly format the code to be a phone number (or any link I wish for that matter) instead of the default home page link.
 
Any help is appreciated. Thank you so much!

-Jared

Share this post


Link to post
Share on other sites

10 answers to this question

  • 0

Posted · Report post

Hi Jared

 

If you could let us know the type of code you have, html/script/php etc then we'll be able to advise the best place to enter it. Most likely it will need to go within a hook in the functions.php of a child theme for that type of action.

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Hi Jared

 

If you could let us know the type of code you have, html/script/php etc then we'll be able to advise the best place to enter it. Most likely it will need to go within a hook in the functions.php of a child theme for that type of action.

I am not sure where exactly to retrieve this information for you.

http://guynesdesigns.com/diamondjim/wp-content/uploads/2013/07/diamond-jim-tyler-header.gif

[attachment=2152:headerf.jpg]

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

<a class="plbrand mainlogo-link" title="Diamond Jim Tyler" href="callto://12148560425">

Thats what I am trying to do.....

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Using the answer from here:
http://stackoverflow.com/questions/13354600/phone-number-with-letters-click-to-call

https://gist.github.com/Pross/11057572

not tested tho...

Where do I insert this code? I tried it in the two places,

"Custom CSS / LESS
Insert custom CSS or LESS styling here. It will be stored in the DB and not overwritten.
Note: The professional way to customize your site is using a child theme, or customization plugin"

and

Header Scripts Pro
Scripts inserted directly before the end of the HTML <head> tag

**

Neither of them yielded any change...

The top one showed the code in black lettering above the header image. The 2nd way showed no change at all. Both remind the banner being clicked and went back to the home page.

 

http://diamond-jim.com/
 

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

it needs to go in the pahe head area, i added script tags to the gist.

Do not put it in the css box, it is javascript not css ;)

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

I put in the code here, as shown.

No difference. Went to it on my phone... clicked it.. nothing.

Code is still there if you want to check it on your phone.

http://diamond-jim.com/

 

2zhk67q.jpg

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

updated the code again, should work now

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

updated the code again, should work now

WORKS!!!!!!!!!!!!!!! <3<3

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Thanks for informing us the issue has been resolved.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0