Jump to content

aeperri

Member
  • Posts

    4
  • Joined

  • Last visited

Posts posted by aeperri

  1. 1 hour ago, creedon said:

    @aeperri

    I'm not seeing a leave button in the header. In general not all elements on a page have an explicit id set.

    However almost all elements can be targeted somehow with a CSS selector. But to know what selector we'd need to see the specific element.

    Yes, sorry, I had to pivot for the client so they didn't get confused. I changed the button to a donate button. But for example, lets say I wanted to use that donate button in the header? Can you use javascript like that on a button? 

     

  2. 1 minute ago, creedon said:

    Ha ha. @paul2009 and I both had the same thought! 🙂

    Great minds! 🙂 And it worked! Thank you so much!

    Bonus question if I may, since you both are rock stars and responded so quickly! If I wanted to apply this same function to the button on my header (Leave this website button) - is there a way I can assign an CSS ID  to that button to have this same functionality work on that button?  If not no big deal, I can make the added bar work. But wondered if there was a simple way to target that specific button.

     

  3. @creedon @paul2009  - I have read this thread 100 times and still can't get this to work correctly on our site, but would love some assistance. This is the link : https://www.empowernowproject.org/  (pw: 84532)

    I followed Inscape's info exactly:

    1. I added the text "quick exit" to a code block in my footer.

    2. Add the custom css to design > custom css  (and successfully changed styling a bit)

    3. Added the code below to settings > advanced > code injection > header

    <script>
    $(document).ready(function(){
        $("#quick-exit").on("click", function() {
          window.open("http://weather.com", "_newtab");
          window.location.replace('http://google.com');
         });
    });
      </script>

    But... nothing happens - no click function. 😞  What am I missing??

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.