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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T19:03:46+00:00 2026-05-24T19:03:46+00:00

I have a search form with a styled search box and button. I have

  • 0

I have a search form with a styled search box and button. I have the button styled with CSS .active & .hover classes. Everything is fine and it looks great however, I’m experiencing a short delay between normal, hover & and active states of the search button (the button will blink between states then states will load seamlessly afterwards.

I was wondering if there is a way to load the CSS on page load with a bit of javascript or if there is another method of getting the button to work seamlessly between states. Any suggestions?

CSS:

fieldset.search {
    border: none;
    width: 480px;
    background-image: url(images/searchbackground.png);
    background-repeat: no-repeat;
    padding-top: 36px;
    padding-right: 20px;
}
.search input, .search button {
    border: none;
    float: left;
}
.search input.box {
    color: #690;
    font-size: 1.2em;
    width: 427px;
    height: 25px;
    margin-right: 7px;
    padding-left: 5px;
    padding-bottom: 3px;
    padding-right: 4px;
    margin-left: 7px;
}
.search button.btn {
    width: 30px;
    height: 30px;
    cursor: pointer;
    text-indent: -9999px;
    background: url(images/search.png) no-repeat top right;
}
.search button.btn:hover {
    background: url(images/search_hover.png) no-repeat top right;
}
.search button.btn:active {
    background: url(images/search_active.png) no-repeat top right;
}

HTML:

<form name="form" action="search.php" method="get">
  <fieldset class="search">
    <input type="text" class="box" name="q" />
    <button class="btn" name="Submit">Search</button>
  </fieldset>
</form>
  • 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-05-24T19:03:47+00:00Added an answer on May 24, 2026 at 7:03 pm

    I believe you are experiencing a flicker effect because the images aren’t loaded by default.

    To prevent this you may want to look into the next pages:
    http://www.maratz.com/blog/archives/2005/06/22/preload-hover-images-in-css/

    And even better is if you use an all-in-one image called a sprite:
    http://css-tricks.com/158-css-sprites/

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

Sidebar

Related Questions

I want to have my submit button to the right of my search form.
I Have a styled search box which uses a background, whenever I click on
I have a search form with a query builder. The builder is activated by
I have a search form in an app I'm currently developing, and I would
I have a search form on each of my pages. If I use form
I have a search form and result list. The form allows the user to
I have a search form used to query service provisions, which I will call
(Using MySQL and PHP) I have a search form that will allow my users
what I have: a google search form (displayed on all pages) a wordpress page
I have a really simple search form with the following Label (Search) Textbox (fixed

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.