Solved

jQuery DIV box colors and sizes

Posted on 2016-09-12
8
69 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:Howard Bash
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 4
8 Comments
 
LVL 57

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:Howard Bash
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:Howard Bash
ID: 41794265
I think I got it!
0
Why Off-Site Backups Are The Only Way To Go

You are probably backing up your data—but how and where? Ransomware is on the rise and there are variants that specifically target backups. Read on to discover why off-site is the way to go.

 
LVL 57

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
 
LVL 1

Author Comment

by:Howard Bash
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 57

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:Howard Bash
ID: 41794359
Great
0
 
LVL 57

Expert Comment

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

Featured Post

Why You Need a DevOps Toolchain

IT needs to deliver services with more agility and velocity. IT must roll out application features and innovations faster to keep up with customer demands, which is where a DevOps toolchain steps in. View the infographic to see why you need a DevOps toolchain.

Question has a verified solution.

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

Introduction JSON is an acronym for JavaScript Object Notation.  It is a text-string data transport mechanism, capable of representing simple or complex data structures in a consistent and easy-to-read manner.  Similar in concept to XML, but more e…
JavaScript can be used in a browser to change parts of a webpage dynamically. It begins with the following pattern: If condition W is true, do thing X to target Y after event Z. Below are some tips and tricks to help you get started with JavaScript …
In this tutorial viewers will learn how add a scalable full-width header using CSS3. Create a new HTML document with an internal stylesheet. Set a tiled background.:  Create a new div and name it Header. Position it with position:absolute at the top…
In this tutorial viewers will learn how to style different bullet points for unordered lists in CSS. Begin with a normal unordered list; the default bullet point is a solid circle: In the CSS, create a defined class of unordered list by typing "ul.S…

707 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