Implicitly changing the display type
One interesting phenomenon is that when you set one of the following 2 sentences for an element (regardless of what type of element was previously, Display:none):
- Position:absolute
- Float:left or Float:right
The element automatically becomes display:inline-block, and of course you can set the width and height of the element and the default width does not fill the parent element.
As the following code, the small partners know that a tag is an inline element, so setting its width is not effective, but set to Position:absolute later, it is OK.
<div class= "Container" > <a href= "#" title= "" > Enter course click here </a></div>
CSS Code
<style>.container a{ Position:absolute; width:200px; Background: #ccc;} </style>
Can't think of what Display:inline-block is doing. Click the element category-inline block element to return to the previous section for review.
Implicitly changing the display type