Jump to content

bobstokes

Members
  • Content Count

    1
  • Joined

  • Last visited

Community Reputation

0 Neutral

About bobstokes

  • Rank
    Newbie
  1. I am trying to change the button text to Call Me when the browser window is 1024 pixels or LESS. The code below works fine until I add the if wi variable. Does anybody have any ideas for making this work? <button id="phone" class="button"><a href="tel:6144788011" title="Call Advanced Systems">614-478-8011</a></button> <!--- Begin Call Button Script ---> <script> var changeText = document.getElementById("phone"); var wi = document.width; if(wi <= 1024){ changeText.innerHTML = "Call Me"; } </script> <!--- End Call Button Script --->
×
×
  • Create New...