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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T13:37:32+00:00 2026-06-03T13:37:32+00:00

hi i am new to css and php too i tried to use it

  • 0

hi i am new to css and php too i tried to use it in my php site i have css as follow in which i am trying to change image on hover but i am getting error and my half images changing only …

enter image description here

while the images i am using are,

enter image description here

enter image description here

my css code is,

#header #nav a {
    float:left;
    margin-left:7px; 
    padding-left:17px; 
    background:url("../design/nav-l.png") 0 -35px no-repeat; 
    text-decoration:none;
}
#header #nav a span {
    float:left; 
    display:block; 
    padding-right:17px; 
    background:url("../design/nav-r.png") 100% -35px no-repeat; 
    line-height:35px;
}
#header #nav a:hover { background-position:0 -100px; }
#header #nav a:hover span { background-position:100% -70px; }

hopes for your reply thanks in advance !

Best Regards,

  • 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-03T13:37:37+00:00Added an answer on June 3, 2026 at 1:37 pm

    You can’t mix % and px on the same CSS value.

    background:url("../design/nav-r.png") 100% -35px no-repeat;
    #header #nav a:hover span { background-position:100% -70px; }

    These two lines are invalid CSS and are probably causing the parser to freak out. Start by setting them using either % or px, but not a combination of both.

    background-position: 100px -35px; <--- OK  
    background-position: 100% 50% <--- OK  
    background-position: 100% 100px <--- Invalid

    If the UI is not behaving correctly after that, you should use a web inspector like Firebug or the inspector built into your browser to see what’s going on under the hood. This will often give you big clues as to what is wrong with your styles.

    If you’re still stuck after trying to fix the problem yourself using a web inspector, update the question with more detail (what have you tried, what was the result) and we’ll have a better shot at helping you fix it 🙂

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

Sidebar

Related Questions

i'm new to drupal, but i have a good knowledge about php, and html/css.
I am pretty new at CSS but have been learning, doing my moms small
I have a small html/css site powered by jQuery, generated with PHP, you can
I'm somewhat new to Javascript, not HTML/CSS or PHP/MySQL, just JS. I have a
I'm very new to WordPress and have no PHP or CSS experience... I'm want
I'm new to jQuery, familiar with PHP & CSS. I have nested, dynamically generated
I am new to PHP, but have a decent grasp of things (have not
I'm new to shadow in css can we set shadows for round image(i mean
I have make a new dropdown navi in css . Chrome, firefox, safari is
I have a php script that loads a CSS stylesheet, changes the color attribute

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.