Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7937119
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T22:26:29+00:00 2026-06-03T22:26:29+00:00

I currently have a tab on my page (created with Jquery UI) that when

  • 0

I currently have a tab on my page (created with Jquery UI) that when clicked expands some content that is collapsed on page load. I want to be able to activate that tab’s action by pressing a separate button on the site. For example, here is the jquery script that makes the tab work it uses Jquery UI core, and the scrollTo plugin:

<script type="text/javascript">
$(function() {
    $( "#tabs" ).tabs({
        collapsible: true,
        selected: -1
    });
});
</script>
<script type="text/javascript">
$(function(){
    $(".scrolltoanchor").click(function(){
        $.scrollTo($($(this).attr("href")), {
            duration: 750
        });
        return false;
    });
});
</script>

And the tab looks like this:

<div id="tabs">
    <ul>
        <li ><a href="#testimonial" class="scrolltoanchor">Testimonials</a></li>
    </ul>
    <div id="testimonial">
        <p>THE CONTENT IS HERE</p>
    </div>
</div>

So I want to put a button elsewhere on the page that expands this content and scrolls to the content, essentially this button, when clicked, will do the exact thing that the “Testimonials” <li> tab does. It would expand #testimonial, and scrolls to it.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T22:26:30+00:00Added an answer on June 3, 2026 at 10:26 pm

    Couldn’t you use the .trigger() function on the element?

    For example, if you had an element with the ID of ‘button’, the following code should do what you want:

    $('#button').click(function(){
        $('.scrolltoanchor').trigger('click');
    });
    ​
    

    jsFiddle example.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a page that is currently generating dynamically created textboxes in a table
Using VB6, I have created an Outlook plugin, that has a property page. The
I currently have a web page that has 2 tabs on it. The 2
there i have created a program with a tab button and page number. all
I have some jQuery tabs set up on the right of the page, however
I have a main page that I want to be a sort of dispatch
I have created Facebook pages with an events tab. I am currently trying to
I currently have a MySQL database that I am accessing using PHP. You search
I currently have the below code, but obviously I am not that skilled on
I currently have: <div class=generic-block-70> <div class=generic-content-70> <table id=voteBlock> // stuff </table> </div> </div>

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.