当前位置: 首页 > news >正文

网站建设要学哪种计算机语言网络舆情分析的内容

网站建设要学哪种计算机语言,网络舆情分析的内容,wordpress建站显示网站图标,聊城网站推广品牌本文用于检验学习效果#xff0c;忘记知识就去文末的链接复习 1. HTML 1.1 HTML基础 结构 头head身体body 内容 图片img段落p图标link 标签 单标签双标签 常用标签 div#xff1a;分割块span#xff1a;只占需要的大小p忘记知识就去文末的链接复习 1. HTML 1.1 HTML基础 结构 头head身体body 内容 图片img段落p图标link 标签 单标签双标签 常用标签 div分割块span只占需要的大小p段落br换行hr一根横线与页面宽度一样h1h2h3h4h5h6一级/二级/三级/四级/五级/六级标题a链接olli有序列表ulli无序列表tebletheadtrthtbodytrtb表格 转义字符 ensp半个空白格子emsp一个空白格子nbsp更小的空白格子ltgtampquotcopy版权reg已注册商标times乘号divide除号 !DOCTYPE html html langenheadmeta charsetutf-8 /titlehello title/titlelink relicon href./img/法案_bill.png typeimage/x-icon / /headbodydiv idanchor1这是页面顶端锚点位置/divh1这是一级标题/h1h2这是二级标题/h2h3这是三级标题/h3div classb1p【这是第1块第1段】/pp【这是第1块第2段】br /《望庐山瀑布》br /唐·李白br /日照香炉生紫烟遥看瀑布挂前川。br /飞流直下三千尺疑是银河落九天。/pp【这是第1块第3段】lt;ensp;gt;lt;emsp;gt;lt;nbsp;gt;/p/divdiv classb2p【这是第2块】/pa hrefhttps://www.bilibili.com/点击这里访问粉色小破站/aol有序列表li这是第一项/lili这是第二项/lili这是第三项/lili这是第四项/lili这是第五项/lili这是第六项/li/olul无序列表li这是第一项/lili这是第二项/lili这是第三项/lili这是第四项/lili这是第五项/lili这是第六项/li/ultable bordertheadtrth学号/thth姓名/thth班级/th/tr/theadtbodytrth001/thth小明/thth计科/th/trtrth002/thth小红/thth软工/th/tr/tbody/table/divdivp【这是第3块】/ppimg width300 src./img/可厉害.png alt可厉害 /img width300 src./img/可厉害.png alt可厉害 //ppimg width300 src./img/可厉害.png alt可厉害 /img width300 src./img/可厉害.png alt可厉害 //ppa href#anchor1跳转到页面顶端锚点位置/a/p/div /body/html1.2 HTML表单写登录界面 标签 labelinputbutton !DOCTYPE html html langenheadmeta charsetutf-8 /titlehello title/titlelink relicon href./img/法案_bill.png typeimage/x-icon / /headbodydivh1登录网站/h1hr /label账号:input typetext nameusername idusername placeholder账号 /br /密码:input typepassword namepassword idpassword placeholder密码 /br /颜色:input typecolor namecolor idcolor /br /选择文件:input typefile namefile idfile /br /选择日期:input typedate namedate iddate /br /备注textarea nametextarea idtextarea cols30 rows10 placeholder多行文本/textareabr /hr /a hrefhttp://www.baidu.com忘记密码/abutton登录/buttonbr //labellabelinput typecheckbox namecheckbox idcheckbox /我同意本网站的隐私政策a hrefhttp://www.baidu.com《隐私政策》/a/labelbrlabelinput typeradio namerole /学生input typeradio namerole /老师input typeradio namerole /管理员br选择身份selectoption value1学生/optionoption value2老师/optionoption value3管理员/option/select/label/div /body/html2. CSS 用CSS自定样式 用外部css文件在元素标签中用style在头部定义样式style CSS选择器指定元素的方式 标签名: input{}直接写class: .test{}(加点)id: #test{}加#所有元素*位于某元素内部的元素div label(所有div标签中的label标签) CSS选择器有优先级(下面从高到低排序) 以最高级为准最高级!important内联选择器ID选择器类选择器元素选择器通配符选择器* CSS边距 浏览器自带边距外边距margin内边距padding 常用属性 background-colormarginpaddingtext-align 制作一个登录界面 !DOCTYPE html html langenheadmeta charsetutf-8 /titlehello title/titlestylebody {background-color: #ffffff;margin: 0;text-align: center;}input {border: 0;background: #e0e0e0;line-height: 40px;border-radius: 20px;padding: 0 20px 0 20px;width: 200px;font-size: 16px;margin-top: 20px;}input:focus {outline: 0;}button {margin-top: 20px;background: #6600CC;border-radius: 20px;border: 0;width: 200px;height: 50px;color: white;font-size: 16px;box-shadow: 0px 2px 10px blueviolet;/*按键四周的阴影*/}button:focus {outline: 0;background: #6666CC;}#input-remember {width: auto;}/style /headbody stylemargin: 0;h1登录/h1formhrdivlabel forinput-username账号:/labelinput typetext idinput-username placeholder账号 /brlabel forinput-password密码:/labelinput typepassword idinput-password placeholder密码 /brlabel forinput-remember记住我:/labelinput typecheckbox idinput-remember /bra href#忘记密码?/aa href#忘记账号?/a/divdivbutton typesubmit登录/button/div/form /body/html3. JavaScript 比起Java更像Python。弱类型语言 3.1 基础语法 数据类型 Number整数小数String字符串Boolean布尔 特殊值 undefined未定义null空NaN非数字值不合法 关键字 let变量不建议用varconst常量typeof a查看变量a的类型 常见语法 aforif-elseswitch-case 关系运算 相等 字符串与数字比较会将字符串转化为数字如1010输出为true 全等这个类似Java中的 逻辑运算短路 逻辑与||逻辑或 7 || true输出7true || 7输出true !逻辑非按位与|按位或?: 输入/输出 console.info()window.alert() 3.2 函数 函数 function f(){/*函数体*/}不用写类型形参返回值 /*函数*/ function ff(param) {console.info(得到的参数param)return 998 }/*函数类型变量*/ let kff k(aa)/*匿名函数*/ let ggfunction(){console.info(这是匿名函数) }function ff(param) {console.info(函数ff得到的参数param)return 998 } /*把函数当作参数传递*/ function pp(fp){fp(函数当做参数传递) } pp(ff)/*把匿名函数当作参数传递*/ pp(function(a){console.info(匿名函数的形参a) }) /*匿名函数另一种写法*/ pp((a){console.info(匿名函数的形参a) })3.3 数组 数组 一个数组可有不同类型元素共存可以动态增加 let arr[23,Hello,false,undefined,NaN] /*会自动扩容*/ arr[15] kkk; /* 插入一个元素到数组后面 */ arr.push(100); /* 从数组后面弹出一个元素 */ arr.pop();fill方法 arr[1,2,3,4,5] /*将数组中的元素全变为1*/ arr.fill(1) console.log(arr) /*将下标[1,3)处的元素变为99*/ arr.fill(99,1,3) console.log(arr);map方法 arr [1, 2, 3, 4, 5]; console.log(arr); /*将数组中的数字全变为字符*/ console.log(arr.map(i i )); /*将数组中的数字全变为字符后面加?*/ console.log(arr.map(i i ?));3.4 对象 /*创建对象*/ let a new Object(); let b {name: bname,age: 18,setName(name) {this.name name;},f: function () {console.log(f function called);}, }; /*动态添加对象*/ a.name aname; a.age 288; a.setName function (name) {this.name name; }; a.setName(哦哦哦); /*若这样写则this不会绑定到a类的对象*/ a.setName (name) {this.name name; };console.log(a); console.log(b); 3.5 事件js与html 常用事件 onclick 点击事件oninput内容输入事件onsubmit内容输出事件 Dom对象 把整个html界面映射为js对象从而可在js中操作html中的元素 getElementById()通过id获取元素 之后可调用元素的属性修改元素 【例子】通过按键改变页面元素值 !DOCTYPE html html langzh-CNheadmeta charsetutf-8title我的网页/titlestylebody {text-align: center;}/stylescriptfunction login_click() {document.getElementById(login-state).textContent 已登录;}function logout_click() {document.getElementById(login-state).textContent 未登录;}/script /headbodyh1登录到xx系统/h1p idlogin-state未登录/pformdivinput typebutton idlogin value登录 onclicklogin_click() /input typebutton idlogout value注销 onclicklogout_click() //div/form /body /html【例子】输入字符长度在[6,20]时正常否则边框变为红色 !DOCTYPE html html langzh-CNheadmeta charsetutf-8title我的网页/titlestylebody {text-align: center;}.illegal-pwd {border: red 1px solid !important;box-shadow: 0 0 5px red;}/stylescriptfunction checkIllegal(e) {if (e.value.length 20 e.value.length 6) {e.removeAttribute(class);}else {e.setAttribute(class, illegal-pwd);}}/script /headbodyformdivlabel forusername用户名:/labelinput typetext idusername nameusername oninputcheckIllegal(this) requiredlabel for password密码:/labelinput typepassword idpassword namepassword requiredinput typesubmit value提交 /div/form /body /html3.6 XHR请求js与后端 通过XMLHttpRequest对象向服务器发送请求 一个发送请求的函数 function httpRequest() {let xhr new XMLHttpRequest();xhr.open(GET, https://www.baidu.com);xhr.send(); }!DOCTYPE html html langzh-CNheadmeta charsetutf-8title我的网页/titlestylebody {text-align: center;}button {width: 100px;height: 50px;margin: 10px;font-size: large;}/stylescriptfunction httpRequest() {let xhr new XMLHttpRequest();xhr.open(GET, https://www.baidu.com);xhr.send();}/script /headbodyh1XHR/h1hrdivbutton stylemargin-top: 20px; onclickhttpRequest()请求/button/div /body/html参考 https://www.itbaima.cn/document/k7dfwua3bsezvw9q
http://www.zqtcl.cn/news/106955/

相关文章:

  • 厦门市网站建设app开发水务 网站建设
  • jfinal网站开发装修公司加盟哪家最好
  • 成都个人网站制作石家庄设计网站公司
  • 阿里巴巴网站本土化建设烟台市两学一做网站
  • 潍坊品牌网站建设公司旅游类作业网站
  • 建设谷歌公司网站费用求职seo推荐
  • 企业网站建设规划ppt企业网站前端模板下载
  • 补习吧 一家专门做家教的网站百度云搜索引擎入口网盘搜索神器
  • 网站建设与制作企业嘉鱼网站建设哪家专业
  • 电脑怎么做网站赚钱柳州柳北建设局网站
  • 农村服务建设有限公司网站设计基础网站推荐
  • 做网站的编程语言组合ppt模板免费的网站推荐
  • 泰安企业建站公司流程上海营销型网站报价
  • 网站承载量怎么做福州公交集团网站建设
  • 新吴区住房和建设交通局网站小程序商城哪家好排行榜
  • 中小学网站建站模板长春火车站咨询电话
  • c2c网站特点公司网站建设亚运村
  • 邢台wap网站建设费用黑帽seo之搜索引擎
  • 如何用阿里云做网站刷题网站怎么做
  • 织梦制作手机网站上海猎头公司名单
  • 免费生成图片的网站wordpress 购物
  • 江西建设部网站国际新闻最新消息今天2023
  • 怎么做网站啊wordpress英文显示改中文
  • 建筑专业网站有哪些网站标题seo外包优化
  • 浙江建设厅网站施工员报名中国建设协会官网站
  • 网站建设优化是干嘛上海今天最新的新闻
  • 网站大全浏览器软文的概念
  • 盐山做网站价格莱芜征婚吧
  • 具有品牌的微网站建设网站设计培训班前台
  • 网站推广工具推荐html网站地图在线生成