I don't know anything about it. I'm new to _html/css_WEB-ITnose.

WBOY
Release: 2016-06-24 11:55:20
Original
1075 people have browsed it

(1) Use DIV CSS to write the following effects as required:
Requirement: Write a centered red div block with a side length of 200px.
In what operating environment are you writing? Please give detailed tutorial on how to do it


Reply to discussion (solution)

Write in notepad, how to do it? Familiar with html and css

Can I preview it after writing it in the notepad? Time is very tight. There are still several questions. This is a team re-examination question

Can I preview it after writing it in the notepad? The time is special There are still a few more questions. This is a team re-examination question


Open it with a browser


ok .

Is the poster a student or working? You don’t know HTML at all.

What company’s re-examination questions... are so cheating~

<div style="width:200px; margin:0px auto">这是红块</div>
Copy after login
Copy after login

I am a student and have just come across these, thank you all.
(2) Use JavaScript and CSS to write the following effects
Requirement: When the mouse moves over the div block, the div color changes from red to blue.
3. Optional questions
(1) Use JavaScript to write the following effect
Requirement: When the mouse pointer clicks on a div block, the div slowly moves to the right (reminder: use the Interval() function ).
(2) Use JavaScript to write the following effect
Requirement: There are three div blocks of different colors side by side in the same row. Click on the first div block and it will change color with the following div block. Click on the second div block. It also changes color with the one behind it. Click the third one and it will change color with the first div block. (Reminder: Event bubbling in JavaScript needs to be solved).

In addition, the search box on the Baidu page also has the following steps:

(2)

  <style>    div{width:100px;height:100px;background:#f00;}  #d1:hover{background:#00f;}  </style>  <div id="d1"></div>  ----------------------------------------  <div id="d2"></div>  <script>    document.getElementById('d2').onmousemove=function(){this.style['background-color']='#00f';}document.getElementById('d2').onmouseout=function(){this.style['background-color']='#f00';}  </script>
Copy after login

The one on the other Baidu page The search box and how to do the following


Audit elements, copy the html to see


In addition, the search box on the Baidu page also has the following how to do it


Review elements, copy the html to see


Don’t forget to copy the style too



In addition, the search box on the Baidu page And how to do the following


Audit elements, copy the html to see


Don’t forget to copy the styles together

How to get all the fonts to the bottom of the page

<div style="width:200px; margin:0px auto">这是红块</div>
Copy after login
Copy after login

Brother, after copying your code, it will be blank
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template