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 8725489
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T08:03:12+00:00 2026-06-13T08:03:12+00:00

HTML: <a href=javascript:void(0); title=Show and Hide id=_showhide> <span id=textsh>hide</span> <div id=contentsShowHide style=display:none;> Contents here

  • 0

HTML:

<a href="javascript:void(0);" title="Show and Hide" id="_showhide">
    <span id="textsh">hide</span>
    <div id="contentsShowHide" style="display:none;">
        Contents here
    <div>

JavaScript:

function headerShowHide(){
$(document).ready(function(){
    $('#_showhide').click(function(){
        $('#contentsShowHide').toggle(function(){$("#textsh").text("show")},function(){$("#textsh").text("hide")});
      });
});}

<div id="contentsShowHide"> is not showing or hiding, and the text is not changing for
<span id="textsh">. What am I missing here?

  • 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-13T08:03:13+00:00Added an answer on June 13, 2026 at 8:03 am

    try this demo

    $(document).ready(function(){
    $('#_showhide').toggle(function(){
        $("#textsh").text("show");
                $("#contentsShowHide").hide();
    }, function(){
                    $("#textsh").text("hide"); 
                        $("#contentsShowHide").show();
    });
    });
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have this code : HTML: <a id=openDiv href=javascript:void(0);>Show</a><br /><br /> <div id=control style=display:none;>
I am creating a Jquery accordion from the following HTML <div class=title><a href=javascript:void(0)>Title goes
Suppose I have this html scenario : <div class=parent> <a href=javascript:void(0); class=child>Link</a> <a href=javascript:void(0);
here's the html for the link, i.e.: <a href=javascript:void(0); style=font-size: 3em; color: #222 class=popover-test
I have this code: <div class=col3> <a id = training-launch-button href=javascript:void(0); title= My title
I have this code: HTML <div class=box_meteo> <div class=box_meteo_pulsanti> <a href=javascript:void(0); class=box_meteo_pulsante id=meteoButton1>Link</a> </div>
My Code is like following in html: <li class=arrow> <div> <a href=javascript:void(0); class=anchor>remove</a> </div>
Hi guys lets say I have the following html: <div class=owner> <div> <a href=javascript:void(0)
there is a script in my html tag <script type=text/javascript> function setTaxDisplay(display) { window.location.href
My HTML: <div class=menu> <a href=javascript:displayonediv('sections1');>Energy Profile</a> <a href=javascript:displayonediv('sections2');>Statistics</a> </div> <div name=sections id=sections1> ....

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.