美文网首页
13-入门:HTTP Node.js HTML CSS 小结

13-入门:HTTP Node.js HTML CSS 小结

作者: 格林姆大师 | 来源:发表于2018-04-23 17:02 被阅读0次

    本节主要复习的知识点:

    1. 计算机是如何存储数据的
    2. 软件安装
    3. 命令行基础
    4. 脚本
    5. HTTP 入门
    6. Node.js Server
    7. HTML
    8. CSS

    1. 计算机是如何存储数据的:
      ASCII码、GBK、unicode、UTF-8.......


      js-13-01.png
    1. 命令行基础:
    • pwd progress working dir
    • cd change dir
    • mkdir make dir
    • touch
    • echo "hi" > 1.txt
    • echo "hi" >> 1.txt 追加
    • echo "hi" >! 1.txt 强制覆盖
    • cp -r copy -recursive
    • rm -rf remove -recursive/force
    • mv
    • tree windows里无
    • git init
    • git add xxx
    • git commit -m"xxx"
    • git pull
    • git push
    • git clone
    • curl -L http://www.baidu.com L-重定向
    • curl -s -v http://www.baidu.com 用来显示请求/响应
    • ping qq.com
    • hexo init
    • hexo g
    • hexo server
    • hexo deploy
    1. HTTP入门
      请求与响应实例:
      a. GET请求与响应
      curl -s -v -H "Frank: xxx" -H "fr: yyy" -- "https://www.baidu.com"
      请求内容:

      > GET / HTTP/1.1
      > Host: www.baidu.com
      > User-Agent: curl/7.55.0
      > Accept: */*
      > Frank: xxx
      > fr: yyy
      >
      

      响应:

      < HTTP/1.1 200 OK
      < Accept-Ranges: bytes
      < Cache-Control: private, no-cache, no-store, proxy-revalidate, no-transform
      < Connection: Keep-Alive
      < Content-Length: 2443
      < Content-Type: text/html
      < Date: Mon, 23 Apr 2018 07:23:45 GMT
      < Etag: "5886041d-98b"
      < Last-Modified: Mon, 23 Jan 2017 13:24:45 GMT
      < Pragma: no-cache
      < Server: bfe/1.0.8.18
      < Set-Cookie: BDORZ=27315; max-age=86400; domain=.baidu.com; path=/
      <
      { [1040 bytes data]
      

      b. POST请求
      curl -X POST -d "1234567890" -s -v -H "Frank: xxx" -- "https://www.baidu.com"
      请求内容:

      > POST / HTTP/1.1
      > Host: www.baidu.com
      > User-Agent: curl/7.55.0
      > Accept: */*
      > Frank: xxx
      > Content-Length: 10
      > Content-Type: application/x-www-form-urlencoded
      >
      } [10 bytes data]
      
    2. html入门:

    <!DOCTYPE html>
    <html lang="en">
    <head>
        <meta charset="UTF-8">
        <meta name="viewport" content="width=device-width, initial-scale=1.0">
        <meta http-equiv="X-UA-Compatible" content="ie=edge">
        <title>草稿测试</title>
    </head>
    <body>
    hello
    </body>
    </html>
    

    注意:

    • <meta charset="UTF-8">,如果后台后设置charset,则以后台为准,权重:后台协议>前端内容;如果浏览器上显示为乱码,什么原因????
    1. css入门:
    • 想要自己找一些好看的页面素材以及psd可以访问以下两个网站;
    • margin与padding---用哪一个可以实现效果就用哪一个,padding与border-box配合使用不错;

    相关文章

      网友评论

          本文标题:13-入门:HTTP Node.js HTML CSS 小结

          本文链接:https://www.haomeiwen.com/subject/yreklftx.html