Solved

jQuery DIV box colors and sizes

Posted on 2016-09-12
8
46 Views
Last Modified: 2016-09-12
I had this question after viewing jQuery Generalization.

Can I ask you one variation?  How can I have the appearing DIV to show a border of say n Pixels thick and a specified color.
0
Comment
Question by:hbash
  • 4
  • 4
8 Comments
 
LVL 51

Expert Comment

by:Julian Hansen
ID: 41794203
Try this
Assuming the code from the sample in the referred question you can try adding this to your CSS
.main-menu + div {
  display: none;
  border: 3px solid black; /* ADD BORDER */
  overflow: hidden;  /* MAKE BOX EXTEND AROUND ALL CONTENT */
}

Open in new window

0
 
LVL 1

Author Comment

by:hbash
ID: 41794226
Would it be possible to have the box rounded?  Also,  it seems that the boxes have more height than the contents require.  Is that something in my DIVs and/or can that be made dynamic?
0
 
LVL 1

Author Comment

by:hbash
ID: 41794265
I think I got it!
0
 
LVL 51

Accepted Solution

by:
Julian Hansen earned 500 total points
ID: 41794306
rounded box
add
.main-menu + div {
  display: none;
  border: 3px solid black; /* ADD BORDER */
  border-radius: 10px;
  overflow: hidden;  /* MAKE BOX EXTEND AROUND ALL CONTENT */
}

Open in new window

0
Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

 
LVL 1

Author Comment

by:hbash
ID: 41794318
Yes.  I have that now.  Thanks...
You're an HTML/CSS GURU!!!!

Can you point me at any tutorials/books/URLs where I can develop my HTML/CSS skills?

Thanks,
H
0
 
LVL 51

Expert Comment

by:Julian Hansen
ID: 41794352
I don't personally have any I can recommend. I mainly use online resources W3Schools / MDN etc.
0
 
LVL 1

Author Closing Comment

by:hbash
ID: 41794359
Great
0
 
LVL 51

Expert Comment

by:Julian Hansen
ID: 41794507
You are welcome.
0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
spacing 5 29
JDeveloper 12c for 32 bit 4 35
HTML page and JavaScript 2 52
gif overlay 3 32
I found this questions asking how to do this in many different forums, so I will describe here how to implement a solution using PHP and AJAX. The logical flow for the problem should be: Write an event handler for the first drop down box to get …
This article discusses four methods for overlaying images in a container on a web page
In this tutorial viewers will learn how add a full-size background image to a webpage using CSS3. Create a new HTML document with an internal stylesheet.: In CSS, define the html element to have a background image. Use a high resolution image.: In t…
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)

705 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

12 Experts available now in Live!

Get 1:1 Help Now