美文网首页
【Chrome】Chrome 调试小技巧

【Chrome】Chrome 调试小技巧

作者: Bogon | 来源:发表于2022-12-08 18:22 被阅读0次

    1. 用Chrome浏览器长截屏

    F12
    ctrl + shift +p
    输入 full size  回车
    
    image.png image.png

    2. 修改UserAgent

    curl 'https://www.douban.com/' \
      -H 'Connection: keep-alive' \
      -H 'Pragma: no-cache' \
      -H 'Cache-Control: no-cache' \
      -H 'sec-ch-ua: " Not;A Brand";v="99", "Google Chrome";v="91", "Chromium";v="91"' \
      -H 'sec-ch-ua-mobile: ?0' \
      -H 'Upgrade-Insecure-Requests: 1' \
      -H 'User-Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36' \
      -H 'Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9' \
      -H 'Sec-Fetch-Site: none' \
      -H 'Sec-Fetch-Mode: navigate' \
      -H 'Sec-Fetch-User: ?1' \
      -H 'Sec-Fetch-Dest: document' \
      -H 'Accept-Language: zh-CN,zh;q=0.9' \
      -H 'Cookie: viewed="1364774"; bid=eJWTAcWFTf0; gr_user_id=dddc3de0-902c-4198-844b-7d93bc4af748; __utmc=30149280; __utmz=30149280.1670481830.1.1.utmcsr=cn.bing.com|utmccn=(referral)|utmcmd=referral|utmcct=/; __gads=ID=1059e01480859c7e-226d6095c8d8007f:T=1670481830:RT=1670481830:S=ALNI_MaWasxYhSosC0-pUyTijzRaKnQTkA; __gpi=UID=00000b8c6f0cd023:T=1670481830:RT=1670481830:S=ALNI_MY-PC0cSqmBUjURT_ddH6pWfimzTg; ll="118282"; _pk_ses.100001.8cb4=*; __utma=30149280.1263758101.1670481830.1670481830.1670493687.2; _pk_id.100001.8cb4=49bcc713c19e25c3.1670493687.1.1670493694.1670493687.; __utmb=30149280.8.9.1670493695337' \
      --compressed
    
    image.png image.png
    "C:\Program Files (x86)\Google\Chrome\Application\chrome.exe"
    

    修改为:

    "C:\Program Files (x86)\Google\Chrome\Application\chrome.exe" --User-Agent="test;Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/108.0.0.0 Safari/537.36"
    

    重启浏览器

    image.png
    User-Agent: test;Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/108.0.0.0 Safari/537.36
    

    相关文章

      网友评论

          本文标题:【Chrome】Chrome 调试小技巧

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