abstract:<!DOCTYPE html> <html> <head> <title>模擬智能在線客服系統(tǒng)</title> <style type="text/css"> .div_1{ width: 45
<!DOCTYPE html> <html> <head> <title>模擬智能在線客服系統(tǒng)</title> <style type="text/css"> .div_1{ width: 450px; height: 650px; background-color: lightskyblue; margin: 30px auto; color: #333; box-shadow: 2px 2px 2px #808080; } h2{ text-align: center; margin-bottom:-10px; } .div_2{ width: 400px; height: 500px; border: 4px double green; background-color: #efefef; margin: 20px auto 10px; } ul{ list-style-type: nene; line-height: 2em; overflow: hidden; padding: 15px; } table{ width: 90%; height: 80px; margin: auto; } textarea{ border: none; resize: none; background-color: lightyellow; } button{ width: 60px; height: 40px; background-color: seagreen; color: white; border: none; } button:hover{ cursor: pointer; background-color: orange; } </style> </head> <body> <div class="div_1"> <h2>在線客服</h2> <div class="div_2"> <ul> <li></li> </ul> </div> <table> <tr> <td class="right"><textarea name="text" cols='50' rows='4'></textarea></td> <td class="left"><button type="button">發(fā)送</button></td> </tr> </table> </div> <script type="text/javascript"> //獲取到頁(yè)面上相關(guān)的元素 var btn=document.getElementsByTagName('button')[0]; var text=document.getElementsByName('text')[0]; var list =document.getElementsByTagName('ul')[0]; var sum = 0; 這是計(jì)數(shù)器 </script> </body> </html>
本節(jié)課主要講了智能在線客服系統(tǒng)的聊天窗口所需的html標(biāo)簽和css樣式,還有就是獲取頁(yè)面中的相關(guān)元素
Correcting teacher:韋小寶Correction time:2018-12-09 09:00:58
Teacher's summary:恩!寫(xiě)的很不錯(cuò)!課后也要記得使用這種小案例來(lái)進(jìn)行練習(xí)哦!