网络

服务器上PHP使用QQ邮箱或者Gmail邮箱的SMTP发信

关键点
smtp地址需要加密:
gmail的smtp地址 【ssl://smtp.gmail.com 】
qq邮箱的smtp地址 【ssl://smtp.qq.com】
端口 【465】

星期六, 3月 22nd, 2014 服务器, 网络 没有评论

微软Visual Studio 2010感人广告五部曲

编程无数,如何编译变幻莫测的爱情?喜怒哀乐是不是最难玩转的代码?爱情真的是一道无解的程序吗?

一个热衷于code的developer,一个热衷于developer的女孩,他们将发生怎样的故事?

来和一位程序员女友一起经历他们的酸甜苦辣,看她真心解密能够爱下去的坚定理由。

微软Visual Studio 2010 第一幕:想做你的code

微软Visual Studio 2010 第二幕:让爱延长

微软Visual Studio 2010 第三幕:幸福要敏捷

微软Visual Studio 2010 第四幕:为爱Debug

微软Visual Studio 2010 第五幕:让爱编译通过


Tags: , , , , , , ,

星期六, 4月 24th, 2010 网络 2 Comments

Ubuntu 10.04 LTS RC发布

今天,2010年4月23日,Ubuntu 开发团队发布了 Ubuntu 10.04 LTS 的 RC 版本。6天以后,也就是2010年4月29日, Ubuntu 10.04 将正式发布

上一张Ubuntu 10.04 LTS RC的截图

ubuntu10.04-lts-rc桌面截图

ubuntu10.04-lts-rc桌面截图

因为是从9.10 update上来的,flash显示中文不正常,用老方法解决这个问题

weiqk@weiqk-laptop:~$ sudo rm /etc/fonts/conf.d/49-sansserif.conf

Ubuntu 10.04:代号“Lucid Lynx”

LTS:长期支持

Tags: , ,

星期五, 4月 23rd, 2010 网络 没有评论

2010年4月3号Google PR更新

2010年4月3号下午发现Google PR在更新,Njava的PR还是维持3,希望下3个月的周期里能有所上升。虽然说不重要了,但是受应试教育的影响,还是很期待这个分数的。同时今天Apple也正式发售IPAD了,希望有一天能弄一个来玩玩

Tags: , , ,

星期日, 4月 4th, 2010 网络 没有评论

什么是UNIX Domain Socket IPC

socket API原本是为网络通讯设计的,但后来在socket的框架上发展出一种IPC机制,就是UNIX Domain Socket。虽然网络socket也可用于同一台主机的进程间通讯(通过loopback地址127.0.0.1),但是UNIX Domain Socket用于IPC更有效率:不需要经过网络协议栈,不需要打包拆包、计算校验和、维护序号和应答等,只是将应用层数据从一个进程拷贝到另一个进程。这是因为,IPC机制本质上是可靠的通讯,而网络协议是为不可靠的通讯设计的。UNIX Domain Socket也提供面向流和面向数据包两种API接口,类似于TCP和UDP,但是面向消息的UNIX Domain Socket也是可靠的,消息既不会丢失也不会顺序错乱。

UNIX Domain Socket是全双工的,API接口语义丰富,相比其它IPC机制有明显的优越性,目前已成为使用最广泛的IPC机制,比如X Window服务器和GUI程序之间就是通过UNIX Domain Socket通讯的。

使用UNIX Domain Socket的过程和网络socket十分相似,也要先调用socket()创建一个socket文件描述符,address family指定为AF_UNIX,type可以选择SOCK_DGRAM或SOCK_STREAM,protocol参数仍然指定为0即可。

UNIX Domain Socket与网络socket编程最明显的不同在于地址格式不同,用结构体sockaddr_un表示,网络编程的socket地址是IP地址加端口号,而UNIX Domain Socket的地址是一个socket类型的文件在文件系统中的路径,这个socket文件由bind()调用创建,如果调用bind()时该文件已存在,则bind()错误返回。

Tags: ,

星期五, 3月 26th, 2010 网络 没有评论

HTTP codes

This is examples of current HTTP codes

#[Miscellaneous successes]
“2xx”, “[Miscellaneous successes]”,
“200”, “OK”, # HTTP request OK
“201”, “Created”,
“202”, “Request recorded, will be executed later”,
“203”, “Non-authoritative information”,
“204”, “Request executed”,
“205”, “Reset document”,
“206”, “Partial Content”,
#[Miscellaneous redirections]
“3xx”, “[Miscellaneous redirections]”,
“300”, “Multiple documents available”,
“301”, “Moved Permanently”,
“302”, “Found”,
“303”, “See other document”,
“304”, “Not Modified since last retrieval”, # HTTP request OK
“305”, “Use proxy”,
“306”, “Switch proxy”,
“307”, “Document moved temporarily”,
#[Miscellaneous client/user errors]
“4xx”, “[Miscellaneous client/user errors]”,
“400”, “Bad Request”,
“401”, “Unauthorized”,
“402”, “Payment required”,
“403”, “Forbidden”,
“404”, “Document Not Found”,
“405”, “Method not allowed”,
“406”, “ocument not acceptable to client”,
“407”, “Proxy authentication required”,
“408”, “Request Timeout”,
“409”, “Request conflicts with state of resource”,
“410”, “Document gone permanently”,
“411”, “Length required”,
“412”, “Precondition failed”,
“413”, “Request too long”,
“414”, “Requested filename too long”,
“415”, “Unsupported media type”,
“416”, “Requested range not valid”,
“417”, “Failed”,
#[Miscellaneous server errors]
“5xx”, “[Miscellaneous server errors]”,
“500”, “Internal server Error”,
“501”, “Not implemented”,
“502”, “Received bad response from real server”,
“503”, “Server busy”,
“504”, “Gateway timeout”,
“505”, “HTTP version not supported”,
“506”, “Redirection failed”,
#[Unknown]
“xxx” ,”[Unknown]”

Tags:

星期四, 3月 11th, 2010 网络 没有评论
1LMooBmUE153Wnd3zDryWvDyXxQudbFxDr