Summary 4.14

Audio video

<audio src = "path" controls = "controls" loop (auto loop) autoplay (enter page autoplay) muted (mute)>

<video src="路径" controls="controls">

 

CSS style sheet reference

<div style = "color: red; border: 2px solid blue; width: 300px;"> first CSS style (inline) </ div>

Inline reference method, add attributes directly in the html file tag.

<head><style>.font_size{color:red;font-size:20px;}</style></head>

<body> <div class = "font_size"> Second CSS style (internal) </ div> </ body>

Internal reference method, modify the attributes in the html cultural head (recommended) section, but still operate in the html file

<link href="style.css" rel="stylesheet" type="css">

<div class = "font_color"> The third CSS style (external) </ div>

style.css

.font_color{

color: purple; text color

font-size: 15px; text size

min-height: 500px; minimum height

max-width: 400px; maximum width

background color

background-image: url ( ./material/LINA1.jpg ); background image

background-position-x: right; background horizontal position, aligned side

background-attachment: fixed; background image does not scroll with the page

background-repeat: no-repeat; whether the background image is tiled, no-repeat is not tiled

background-size: 300px 400px;} background width height

For external reference, create a new css file and write the attributes that need to be modified into the css file in this format, XX element name, .XXclass class name, #XXid name Then use link href = "pathname" to refer the css file to the html file.

Guess you like

Origin www.cnblogs.com/HighKK/p/12699570.html