显示下一条  |  关闭

Zeal Lights Future

Sense & Simplicity

 
 
 
 
 
 

海外 美国 狮子座

 发消息  写留言

 
Sense and Simplicity
 
近期心愿Concentrate all my energies on learning and working
博客等级加载中...
今日访问加载中...
总访问量加载中...
最后登录加载中...
 
 
 
 
 
 
 
模块内容加载中...
 
 
 
 
 

日历

 
 
模块内容加载中...
 
 
 
 
 

天气

 
 
模块内容加载中...
 
 
 
 
 

网易新闻资讯

 
 
 
 
新闻标题 
列表加载中...
 
 
 
 
 
 
 
博友列表加载中...
 
 
 
 
 
 
 
模块内容加载中...
 
 
 
 
 
 
 
 

Maintain CSS sprite images with CSS code automatically

2012-2-7 3:15:17 阅读63 评论0 72012/02 Feb7

As known to us, it will reduce the HTTP connections between browser and HTTP server if we sprite the small image assets together into a single image.

But to reference the image assets in the web pages, we need to create some CSS attributes, like:

background-image:url(path-to-your-image.file);background-repeat:no-repeat;display:block;overflow:hidden

width:--px;height:--px;background-position:--px --px

So we have to make the CSS code together with the sprite image synced when some of the image assets were updated. If we do it manually, it is definitely very boring. Let's get it automatically.

The green line of CSS attributes could be shared over all the sprite

作者  | 2012-2-7 3:15:17 | 阅读(63) |评论(0) | 阅读全文>>

Set up Apache + MySQL + Django on Windows

2012-1-8 9:35:51 阅读94 评论1 82012/01 Jan8

Follow this guide to set up a Django development environment on Windows.

Step 1: Install Apache and MySQL.

Just to simplify the installation, I would to recommend to use WAMP which contains Apache, MySQL and PHP engine. Cause I didn't find the x64 version of mod_wsgi for Apache, so let's keep all components x86 (32 bit). The WAMP version I am using is 2.2a, installer file name WampServer2.2a-x32.exe. Recommend to install WAMP to the default folder C:\wamp.

After installation, we should have phpMyAdmin to manage MySQL database at 

作者  | 2012-1-8 9:35:51 | 阅读(94) |评论(1) | 阅读全文>>

15个非常好用的Windows7快捷键

2012-1-5 6:32:19 阅读56 评论1 52012/01 Jan5

任何的操作系统、软件、游戏,只有熟练使用快捷键,才能最大效率的工作、娱乐,我们不能把所有的时间都浪费在一台机器上,这是不行的。快捷键带给我们的不只是快速,还能感受到机器带来的快感。 

1. Ctrl + Shift + N ? 创建一个新的文件夹  

你需要在文件夹窗口中按 Ctrl + Shift + N 才行,在 Chrome 中是打开隐身窗口的快捷键。

2. Ctrl + Shift + 左键 ? 用管理员权限打开程序 (Ctrl+Shift+Click to Open a Program As Administrator)  

有些程序,需要右键选择 Windows7 的管理员权限才可以正常运行,而这个蛋疼的快捷键我没有测试成功,@sfufoet 在受限制帐户下测试的软件 AirVideoServer 可以在 Touch 上成功连接 AirVideoServer 并播放视频。  

3. Shift+ 鼠标右键 ? 增强版右键发送到  

右键发送到 是一个很常用的功能,一般情况下可以发送到:桌面快捷方式、邮件联系人、压缩文档、移动设备等等。而通过 Shift+ 鼠标右键 的发送到,增加了 Windows7 个人文件夹内的所有内容,包括:我的文档、我的照片、我的音乐、桌面等等。

4. Shift + 右键 ? 在当前文件夹用命令行打开。      

开始 > 运行 > cmd 就是命令行界面,传说中的 DOS 命令。最常用的可能就是 ping 了吧?用

作者  | 2012-1-5 6:32:19 | 阅读(56) |评论(1) | 阅读全文>>

CGI, FCGI, SCGI, WSGI 释异

2011-12-29 7:35:09 阅读86 评论0 292011/12 Dec29

WIKI Links:

CGI - http://en.wikipedia.org/wiki/Common_Gateway_Interface

FCGI - http://en.wikipedia.org/wiki/Fcgi

SCGI - http://en.wikipedia.org/wiki/SCGI

WSGI - http://en.wikipedia.org/wiki/Wsgi

Other reference:

http://helpful.knobs-dials.com/index.php/CGI%2C_FastCGI%2C_SCGI%2C_WSGI%2C_servlets_and_such#FastCGI_and_SCGI

CGI = Common Gateway Interface

顾名思义,它是一种接口规范。该规范详细定义了Web服务器中运行的服务器代理程序,怎样获取及返回网页生成过程中,服务器环境上下文和HTTP协议中的参数名称,如大家所熟知的:REQUEST_METHOD,QUERY_STRING,CONTENT_TYPE等等。绝大部分的Web服务器程序,是以脚本的形式代理接受并处理HTTP请求,返回HTTP页面或响应。这些脚本程序,就是大家所熟知的PHP、ASP、JSP等等。

FCGI = Fast CGI

它其实是CGI在具体实现中的的一个变种。其设计思路是,通过减少CGI代理程序和We

作者  | 2011-12-29 7:35:09 | 阅读(86) |评论(0) | 阅读全文>>

Django 学习资料汇总

2011-10-5 8:17:31 阅读179 评论0 52011/10 Oct5

Django构建一个Blog入门例子

1、创建项目文件。windows下,在cmd中,进入Django项目存放的目录下,比如在D盘符中,取名为mysite,进入D盘,输入:

python django-admin.py startproject mysite

可以看到在D盘中新生成了一个Django项目文件名为mysite,文件中包含

__init__.py # 在python中,__init__.py文件说明此项目目录为一个python包

manage.py # Django管理工具使用manage.py help查看其使用方法

settings.py # 项目的默认配置,放置的一些静态变量

urls.py # 配置django URL映射

2、启动服务器。在此目录下,输入:

python ./manage.py runserver # 启动Django

输入127.0.0.1:8000即可看到It‘s working字样

3、创建项目web应用文件。输入:

python ./manage.py startapp blog

作者  | 2011-10-5 8:17:31 | 阅读(179) |评论(0) | 阅读全文>>

查看所有日志>>

 
 
 
 
 

有道博客搜索

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

页脚

网易公司版权所有 ©1997-2012

   
创建博客 登录  
 关注