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

  • Home
  • SEARCH
  • 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 8708291
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T04:05:46+00:00 2026-06-13T04:05:46+00:00

I have some jQuery which i think could be written a lot simpler, I

  • 0

I have some jQuery which i think could be written a lot simpler, I am new to jQuery, I would also like to add a slide in and out animation to the code but not sure how best to do this. Any help would be great.

$(document).ready(function() {
  $('.utilTabFilter').click(function() {
    if($('#sideFilter.smallScreenFilter').css("left")=="0px")
    {
        $('#sideFilter.smallScreenFilter').css("left","-232px");    
        $('.smallScreenFilter .utilFollowFilter').css("display","none");
    }
    else
    {
        $('#sideFilter.smallScreenFilter').css("left","0");
        $('.smallScreenFilter .utilFollowFilter').css("display","block");
    }       
  });
});
  • 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-13T04:05:48+00:00Added an answer on June 13, 2026 at 4:05 am

    Put your style into CSS class:

    .myClass { left: -232px }
    

    and toggle it on click. Plus use .toggle() method to toggle visibility:

    $('.utilTabFilter').click(function() {
       $('#sideFilter.smallScreenFilter').toggleClass('myClass');
       $('.smallScreenFilter .utilFollowFilter').toggle();
    });
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a JQuery control which has some private methods. I would like to
I have some jquery which will calculate the items in my menu and assign
I have some jquery code which I am trying to translate to YUI. I
I have some tabs using jQuery UI which work just fine, but I want
I have some jQuery code, which attempts to show the first 6 divs on
I have some onchange events setup in jQuery which are used to populate a
I have some javascript which I want to convert to jQuery... I thought it
I have a page which loads and then I do some JQuery upon it.
With jQuery ajax method I have a request on some file, which returns data
I have some jQuery code like this : $(function($) { $('input.autonumeric').autoNumeric({aSep: ',', aDec: '.',vMax:'1000000000000'});

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.