Solved

hover

Posted on 2013-05-30
8
441 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 33

Expert Comment

by:paulmacd
Comment Utility
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
Comment Utility
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 51

Expert Comment

by:Julian Hansen
Comment Utility
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
 
LVL 53

Expert Comment

by:COBOLdinosaur
Comment Utility
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
What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

 

Author Comment

by:TimSweet220
Comment Utility
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 51

Accepted Solution

by:
Julian Hansen earned 500 total points
Comment Utility
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
Comment Utility
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 51

Expert Comment

by:Julian Hansen
Comment Utility
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

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

Styling your websites can become very complex. Here I'll show how SASS can help you better organize, maintain and reuse your CSS code.
Not sure what the best email signature size is? Are you worried about email signature image size? Follow this best practice guide.
The purpose of this video is to demonstrate how to exclude a particular blog category from the main blog page. This is can be used when a category already has its own tab, or you simply want certain types of posts not to show up on the main blog. …
The viewer will learn the benefit of using external CSS files and the relationship between class and ID selectors. Create your external css file by saving it as style.css then set up your style tags: (CODE) Reference the nav tag and set your prop…

772 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

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now