string(2) "33" Development | Marco Nie
分类 Development 下的文章

The Hypertext Transfer Protocol (HTTP) is an application protocol for distributed, collaborative, hypermedia information systems.[1] HTTP is the foundation of data communication for the World Wide Web, where hypertext documents include hyperlinks to other resources that the user can easily access, for example by a mouse click or by tapping the screen in a web browser.

以上说明摘录自 Wikipedia,HTTP 全称为超文本传输协议,设计HTTP最初的目的是为了提供一种发布和接收HTML页面的方法。通过HTTP或者HTTPS协议请求的资源由统一资源标识符(Uniform Resource Identifiers,URI)来标识。

阅读全文


一般浏览器都可以将当前页面输出为 pdf,但当有很多个 html 文件时一个一个转换就很麻烦了,可以使用 wkhtmltopdf 命令行工具来实现自动化批量转换。

wkhtmltopdf and wkhtmltoimage are open source (LGPLv3) command line tools to render HTML into PDF and various image formats using the Qt WebKit rendering engine. These run entirely "headless" and do not require a display or display service.

wkhtmltopdf 官网:https://wkhtmltopdf.org/
GitHub 主页:https://github.com/wkhtmltopdf/wkhtmltopdf

阅读全文



最近自己做了一个 typecho 的主题,主要是手机端的页面优化和字体优化,使用了 bootstrap 来渲染,主题在 GitHub 上开源:https://github.com/nie11kun/TypechoAwesome

但是测试发现搜索框无法正确搜索,总是返回主页。

今天终于发现问题所在了,由于我的网站使用的 NS 服务是 cloudflare 的,在当时设置的时候,把移动端 Mobile Redirect 优化选择上了,每次访问网站都会重定向到 m.niekun.net,估计是 cf 做了什么精简,导致功能丢失,把 Mobile Redirect 关闭就正常了。

具体修改路径是 speed - optimisation:
2020-03-03T14:33:02.png

页面拉到最下方,将 Mobile Redirect 关掉:
2020-03-03T14:33:36.png

再次访问主页,就不会重定向到 m.niekun.net 而是 niekun.net 了。


2020-02-28T08:41:44.png

aria2 是一款轻量级的下载器,支持 HTTP/HTTPS, FTP, SFTP, BitTorrent and Metalink 等多种协议。

它有如下特点:

  • 多节点链接:下载一个文件可以同时链接多个源来提速
  • 轻量级:占用系统资源极少,一般下载任务内存占用 10mb 内
  • 全功能的 BitTorrent 客户端:支持 DHT, PEX, Encryption, Magnet URI, Web-Seeding, Selective Downloads, Local Peer Discovery and UDP tracker
  • 支持 metalink 链接
  • 支持远程控制:支持 RPC 界面控制 aria2 进程

官网:https://aria2.github.io/
GitHub 主页:https://github.com/aria2/aria2
webui-aria2:https://github.com/ziahamza/webui-aria2

阅读全文