Questions tagged as 'css'

3
answers

How to horizontally center one div within another?

How can I horizontally center a div that is inside another div using only CSS? In this case, we can assume that div external outer has width of 100%. <div id="outer"> <div id="inner">Este é o elem...
asked by 21.12.2013 / 16:27
4
answers

Is it necessary to add prefixes in some CSS properties?

In many browsers, browser compatibility prefixes are added to CSS attributes. Example: .exemplo { -webkit-background-size: 50% 50%; -moz-background-size: 50% 50%; -o-background-size: 50% 50%; background-size: 50% 50%; } But if you l...
asked by 01.02.2014 / 00:59
2
answers

What does the + sign mean in CSS?

For example: .input__field--minoru:focus + .input__label--minoru::after { } I'm making an effect here, but I'm not understanding this + sign in the framework. Final score $(document).ready(function() { $(".campo")....
asked by 07.10.2015 / 18:03
4
answers

How to apply readonly in a select?

I think most here know the difference between readonly and disabled . Select Readonly readonly does not apply correctly to select <select name="field" readonly="readonly"> <option value=""...
asked by 12.05.2016 / 19:43
2
answers

What is the "important" statement for?

What is the !important statement in CSS? body { font-size: 12.5px !important; }     
asked by 14.07.2014 / 15:03
4
answers

How do I set a "horizontal menu" at the top of the window when scrolling the page?

I have a layout with a horizontal navigation bar at the top of the site, it has margin-top:100px , when scrolling the page the menu should be set at the top of the window but with margin-top:0 . What is the best way to accomplish...
asked by 04.02.2014 / 16:51
2
answers

How to leave a responsive image

I'm working on a site with a responsive feature and I have a promotions page and I would like the images to accompany the size change of the browser, the maximum size of the image is 1080px, following some companions' tips example shown separate...
asked by 09.02.2015 / 12:59
1
answer

Which css selector has priority?

My question is very objective. Regarding css selectors. I have the following code HTML and CSS : #element p{color:blue;} .element p{color:red;} div p{color:pink;} div.element p{color:yellow;} div[name="ele...
asked by 01.08.2016 / 19:27
3
answers

br is obsolete?

With the advent of responsive / adaptive / fluid layouts, it is becoming less common to use <br> to define layout spacing. Is not it recommended in these modern layouts or is it just a matter of programming practice to separate resp...
asked by 07.06.2018 / 16:11
2
answers

Any way to style "parent" element with CSS

Hello, is there any way to select the parent element of another element with CSS? To be more specific, I am studying in localhost using the phpBB3 forums platform, when a message is grateful it gains the .bg1 class (the default being...
asked by 24.04.2014 / 19:03