Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums JavaScript Show More/Less help

  • This topic is empty.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #157006
    socorock84
    Participant

    I’m having trouble trying to get some text to show more/less. Click here to view the site

    Once you click the link, click the ‘websites’ tab on the side nav

    It’s the first div box called Agent/broker websites. When you click more info i want it to show the hidden text but it’s not working properly. Any help would be very appreciated.

    `var $clickme = $(‘.clickme’),
    $box = $(‘.box’);

    $box.hide();

    $clickme.click( function(e) {
    $(this).text(($(this).text() === ‘Hide’ ? ‘Show’ : ‘Hide’)).next(‘.box’).slideToggle();;
    e.preventDefault();
    });`

    #157336
    socorock84
    Participant

    Awesome, that did it. Just stared with jquery so new to all of this. Thanks for your help.

Viewing 2 posts - 1 through 2 (of 2 total)
  • The forum ‘JavaScript’ is closed to new topics and replies.