Solved

hover

Posted on 2013-05-30
8
447 Views
Last Modified: 2013-05-30
how do i adjust the box when the text is hovered over.


for example as you can see from the screen shot  when the mouse is over the word the box appears from the css tag called hover

i want to make the box height smaller so the box doesn't cover the above text

how do i do that ?

is there a property that i have to set in the hover attribute ?
Screen-Shot-2013-05-30-at-9.36.3.png
0
Comment
Question by:TimSweet220
8 Comments
 
LVL 34

Expert Comment

by:Paul MacDonald
ID: 39208447
I'm sure the "box" is just the container the text is in.  Change the size of that and I'm sure you'll be set.
0
 

Author Comment

by:TimSweet220
ID: 39208661
That didn't help the hover has rules as seen below if i change the border-raduis it makes it a oval shaped so it is changing but  it is in an oval now not rectangle


ul#storeslist li li:hover {
	background: rgba(204,204,204, 0.2);
 	-moz-border-radius: 4px;
  	-webkit-border-radius: 4px;
  	border-radius:4px;
  	border: 1px solid #ccc;
  	position:relative;
	behavior:url(http://preview.drawbackwards.com/PIE.php);
	z-index:0;
  	cursor:arrow;
  	margin: -1px 0;
	
}

Open in new window

0
 
LVL 55

Expert Comment

by:Julian Hansen
ID: 39208670
Give us some code or some kind of clue as to how that part of the page is marked up and maybe we can help you.
0
Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
LVL 53

Expert Comment

by:COBOLdinosaur
ID: 39208709
If reducing the height changes the shape, then just also reduce the radius to 2px.

We are not going to play guessing games. just post the link and we will look at it.

Cd&
0
 

Author Comment

by:TimSweet220
ID: 39208867
i can attach the style.css file
in there you will find the storelist properties and attributes
also there you will find ul#storeslist li li:hover
the site is not in production so i cannot paste link


i just want to reduce the height of it the page code is listed below
<div style="margin-top:-30px; border-radius:4px; height: 50px;">
<li style="margin-left: -5px; margin-bottom: -7px; margin-top: -30px;"><a href="http://test.bookmanstest.com/stores/bookmans-sports-exchange/"><h5>Sports Exchange</h5></a></li>
<li>3330 E. Speedway Blvd.
Tucson, AZ 85716
(520) 881-7329
<a href="/stores/sports">View details</a></li></div>

Open in new window

  this code is just for the sports exchange part of page which is box i want to adjust and make smaller
style.css
0
 
LVL 55

Accepted Solution

by:
Julian Hansen earned 500 total points
ID: 39208983
I would say your problem is here

<div style="margin-top:-30px; ...
<li style="margin-left: -5px; margin-bottom: -7px; margin-top: -30px;" ...


You are applying a negative margin which is going to shif the block up.

I would get rid of the negative margin's - I don't think they are necessary here or at least by styling your page differently you can get rid of them.

Do you have a live link we can look at - tried the test.bookmanstest.com but that does not appear to work.
0
 

Author Comment

by:TimSweet220
ID: 39209159
where this site is place is on a private server so the link is not accessible.
i want the block to stay in the same position but just the highlight box when you hover to become smaller

i think i would have to create a new class in the style.css file because if i alter the hover for storelist it will affect all the hover boxes on the page for storelist  
so maybe i need to create a new class

but then i still dont know how to make the box smaller i cnaged the radius it makes it smaller but it also makes it oval shaped i added a height to it and it made it larger i also added a width it also changed it
so what tags out of the  this line of code alters the size and keeps the rectangle shape
ul#storeslist li li:hover {
	background: rgba(204,204,204, 0.2);
 	-moz-border-radius: 4px;
  	-webkit-border-radius: 4px;
  	border-radius:4px;
  	border: 1px solid #ccc;
  	position:relative;
	behavior:url(http://preview.drawbackwards.com/PIE.php);
	z-index:0;
  	cursor:arrow;
  	margin: -1px 0;
	
}

Open in new window


this code is also found in the style.css
0
 
LVL 55

Expert Comment

by:Julian Hansen
ID: 39209253
None of them

Height is here

<div style="margin-top:-30px; border-radius:4px; height: 50px;">

I would change the way you have marked up this page - you are trying to patch a badly constructed page.
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

CSS is a visual language used to classify objects and define rules about how they should be displayed. CSS skills aren’t restricted to developers anymore, there is a big benefit to having a basic understanding of the language, regardless of your occ…
Not sure what the best email signature size is? Are you worried about email signature image size? Follow this best practice guide.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

861 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question