Most voted "css" questions
Cascading Style Sheets (or simply CSS) is a style language used to define the presentation of documents written in a markup language, such as HTML or XML. Its main benefit is to provide the separation between the format and content of a document.
Learn more…8,314 questions
Sort by count of
-
3
votes2
answers4674
viewsPick top, left element position according to parent element
I’m using jquery offset to pick the position of an element and I’m using draggable to move this element. The offset element is inside a div and I would like to take its position by the parent…
-
3
votes1
answer219
viewsleave a responsive image horizontally, but not scaled, but cut horizontally
Good afternoon How to leave a responsive image, so that it is literally cut in its horizontal, so that you remove the horizontal scrollbar from the page, and do not get a "smashed up appearance" I…
-
3
votes2
answers205
viewsHow to return hexadecimal color randomly
I’m wanting to each build change the css of my application randomly. Example: $menu-color: #0097a7; // retonar apenas uma cor $menu-color: random(#0097a7,#FAFAFA,#7FB800); // retorna uma color…
-
3
votes1
answer398
viewsInput[number] accept numbers only in Firefox
How do I make the input[number] field accept only numbers in Firefox? In Chrome, Opera and Edge works perfectly, but in Firefox the[number] field accepts letters and spaces. <input type="number"…
-
3
votes2
answers1323
viewsGet CSS by Javascript
Is there any way to get the list at all CSS applied to an element by Javascript? Example: Let’s say I have the following element HTML: <div id="mega">Content</div> I also have the CSS:…
-
3
votes1
answer178
viewsNth-Child selection in a table with even columns
Hello I want to get the following result with css: I know with :nth-child: odd and :nth-child: even selects the odd and odd pairs, but in the way I want it would be something like this: No, yes,…
cssasked 7 years ago Lennon S. Bueno 2,182 -
3
votes1
answer659
viewsHow to reveal items when arriving on a particular scroll
I would like to know how to do the effect of revealing items when the scroll of the page reaches the element, example of this site: http://www.metodistapirassununga.org/ The effect is on the blocks…
-
3
votes1
answer436
views -
3
votes4
answers190
viewsWhat is the default value of the "cursor" attribute?
What is the default value of the "cursor attribute"? I changed the value to pointer, but in a certain case I prefer to return to the default arrow, but I don’t know what is the value.…
cssasked 7 years ago Wallace Maxters 102,340 -
3
votes1
answer146
viewsJquery Mobile: Change page background color
How can I override the stylization of this file css to change the background color of the page? I’ve tried using the !important in the background of body and yet it’s no use. I know it is this file…
-
3
votes4
answers943
viewsAdjust one td css only
I have a table: <table border="2"> <tbody> <tr> <td><img class="imgpadrao" src="xxxxx" alt=""></td> <td> Recebido </td> </tr> </tbody>…
-
3
votes3
answers38304
viewsPosition DIV in the center of the page
How do I align the div with black and transparent background where it contains the buttons in the center of the page independent of the monitor resolution? The code I’m using is this: .fundo{…
-
3
votes1
answer261
viewsHow to position button and . page-header in the same Row (inline)
I am using the bootstrap for a simple and helpful panel of you regarding the positioning of certain elements on the page. I would like to position the save button along with the .page-header. But…
-
3
votes1
answer29
viewsHow to make element appear only for Mozilla Firefox users
I have a site that is not half misaligned on Mozilla Firefox, I tested in some browsers, including the Internet Explorer, who by the way displayed the page perfectly. Only the Mozilla Firefox You…
-
3
votes1
answer805
viewsMPDF - Start pagination with variable numbering
I have an application and need to print a document using the class mPDF, however, I need the number of the paging start, for example from the number 43, 44, 45 and so on and not from the 1, 2, 3,…
-
3
votes2
answers907
viewsHow large is the screen for CSS to consider as a desktop?
I want to use this code only when it’s desktop. What size for media query? overflow-y: hidden; // hide vertical overflow-x: hidden; // hide horizontal…
-
3
votes3
answers46057
viewsFooter at the end of the document
I am trying to leave the footer at the end of the document, but it is at the end of the page I am viewing, thus hindering the usability of the system... Follow the footer: <div class="container…
-
3
votes2
answers2477
viewsCSS-only carousel: problems centering and fixing size
I have a carousel created with only CSS, but I have identified some difficulties. All images are in the 4:3 ratio and may have until 640x480 px (i.e., may be less than this value), so: I cannot…
-
3
votes1
answer1061
viewsinput:checked is not applying the properties
I’m developing a responsive menu using css3 (I can’t use JS), and I’m having a problem that’s keeping me from moving forward, the problem is the following : input:checked ~ nav { display: none; }…
-
3
votes1
answer58
viewsI can’t get value from date-Object
There is the following problem I have several inputs listed with the same css class, but I need to take a data-attribute from each one by clicking on the respective input to get its attribute value:…
-
3
votes2
answers25262
viewsRemove edge that separates columns from a table
Good evening! I’m trying to remove the edge that separates the columns from a table but doesn’t work. The Table is this: <table border="0"> <td> <tr> <img…
-
3
votes2
answers3531
viewsIs it possible to change a text from a "content" of a pseudo-CSS element through Javascript?
Example below #test{ content:"blablabla"; }
-
3
votes1
answer70
viewsIs it safe to use grouped media queries?
All topics I found regarding media queries grouped are a few years. With the wide range of CSS3, grouped media queries are now considered safe to use in production? Do any browsers that support CSS3…
-
3
votes1
answer1158
viewsTable with different size?
Hello! I am breaking my head to try to make my table with the left column bigger than the direct column. And I’d really like someone to help me. /* Post Table */ le#alter tr td {background: #fff;}…
-
3
votes1
answer56
viewsUser see current version of Jquery and CSS without cache
Every time I update the CSS and JQUERY from a website, I need to keep asking the customer to open the site in an anonymous window. Because his browser saves the old files and he can’t see the…
-
3
votes1
answer591
viewsResponsive image adjustment in div box
I’m having difficulty making this image fit inside the box, I want regardless of the size of the screen the box always appears in the same place (OK) and the image inside fits the size of the box…
-
3
votes1
answer57
viewsRestrict CSS to IE
Is something missing in this parameter ? I need this style to apply to IE 11 only, when I include this code it works, but other browsers tbm take <!-- [if gte IE 8]--> <style> .box-form…
-
3
votes2
answers170
viewsJava Script Animation
Good afternoon, I’m trying to do a job with css,html,js . I need to make some images slide right and left as soon as I scroll the bar, one image at a time, but as soon as I scroll the images scroll…
-
3
votes1
answer80
viewsImage does not appear 100%
I’m trying to create a LandingPage but the first image is being cut I’m using this CSS: .parte1 { min-height: 100%; max-height: 100%; padding-top: 50px; padding-bottom: 50px; text-align: center;…
-
3
votes3
answers899
viewsDiv on DIV Fixed
I have a div container with height and width 90%, It’s the way I want it! Even if I zoom out, it stays fixed without zooming in or out. What I’m trying to do is a div superimpose that div container…
-
3
votes2
answers14245
viewsCSS Hide Elements using css only
Given the following code snippet: <div class="ui stackable inverted blue container menu"> <a class="item" href="/menu"> logo </a> <a class="item" href="/menu"> <i…
-
3
votes2
answers735
viewsSource with low html quality
body{ background: url('imagens/capa.png'); font-family: "Avantgarde", "TeX Gyre Adventor", "URW Gothic L", sans-serif; } .texto-capa{ text-align: center; color:white; display: table-cell;…
-
3
votes1
answer382
viewsHow to rotate a letter?
I’m trying to rotate a letter of a word to make it look like the company logo. This would be the Logo: Here’s the code I tried to use to rotate <h1 class="text-center"><span…
-
3
votes1
answer264
viewsDropdown div menu with different width in browsers
I dropdown menu and for some reason the width of the div is different in the browsers The div class is the dropdown-content Follow the code and prints .header-menu { height: auto; float: right;…
-
3
votes3
answers3242
viewsLoad HTML from another HTML
I would ask for help in loading inside my main HTML file external files from 2 other HTML pages Below follows the Nav <!DOCTYPE html> <html lang="pt-br"> <head> <meta…
-
3
votes3
answers449
viewsAlignment of text vertically
I’m trying to align the text to the center of the screen, I tried to use the transform:translateY(-50%) with the top:50% in position:absolute, but it didn’t work, I’d like to know how to fix it, and…
-
3
votes2
answers376
viewsBackground with text background
How do I make this effect of letters on top of the image that is like Background, or how I search for it in google?…
-
3
votes2
answers21
viewsLast elements of a class running incorrectly
See this print that you will understand what is happening: http://imgur.com/a/B0zkV I’ve checked the code several times and apparently found no error, follows the html and css part of this class:…
-
3
votes2
answers99
viewsImages in Divs
I have a question about divs with imagens in the case, the doubt is as follows: If I have a div, with 400x400, how do I make an image with 200x400 (or other resolution) fit by occupying the total…
-
3
votes2
answers1060
viewsPrevent browser autocomplete
There is how to prevent, through code, the browser to make suggestions to fill in the login form? It is that the system will be used in laboratories and it would be boring the browser to suggest all…
-
3
votes1
answer631
viewsImage inside an SVG
I’m using a svg, and inside it I put an image I get from a variable by Angularjs. So far so good, the image appears normally, but I want to leave it at width 100%. I’ve tried everything and it…
-
3
votes1
answer37
viewsAttribute with 2 words does not take CSS
Hello, because this attribute using 2 words does not catch, and what I use only 1 word catches <li data-nome="testejunto">Teste</li> Catching example: .item[data-nome=testejunto] {…
-
3
votes3
answers1169
viewsMap with dynamic size at div height
I have a map, and I need it to occupy the height of the div, so if I change the resolution and the div lowers the height, it will be in the dynamic position. If it is an angular solution, it would…
-
3
votes2
answers964
viewsLeave image with the <img> proportional tag in relation to div
I want to leave the proportional image inside the div, but I’m not getting it. The only "solution" I have found so far is to put Object-fit: cover, but this style is not compatible with many…
-
3
votes1
answer1416
viewsPin menu to top of page when scrolling down
I have a div with height 100% and after it a navbar. I would like that when you scroll down the page the navbar fixed at the top of the page. CSS ul.navbar { list-style-type: none; margin: 0;…
-
3
votes2
answers95
viewsWhat is the combination of table and float?
Everyone who deals with web programming has been through this: .children { float: left; } <div class="parent"> <div class="children"> Teste </div> </div> If you use the…
-
3
votes2
answers1000
viewsDifferent layout on other computers?
I’m with a project and this project was all done from scratch on my PC, however when I took my project to another PC that had a monitor resolution totally different from mine, the images and certain…
-
3
votes2
answers576
viewswhat’s the difference in using #my_div or div#my_div
I wonder if there is any difference at the time of the styling of a page using div#minha_div or #minha_div, and another difference is influenced to put the whole path of the div that will be…
-
3
votes2
answers8310
viewsfloating div accompany page scroll
Would anyone have any SIMPLIFIED idea or example of how to make a floating div roll together with the scroll of the page ? Something very simple, for understanding and learning, because the ones…
-
3
votes1
answer1476
viewsPlace Font Awesome icons inside the sorted lists in the menu
Colleagues. I have a Bootstrap menu that I’d like to place the Font Awesome icons next to each item in that menu. HTML looks like this: <ul class="dropdown-menu"> <li><a…