2013年4月6日

Win7 启用 Telnet

摘要: 开启后一般会默认为禁用,要到服务启用。设置好后进入cmd > net start telnet 阅读全文

posted @ 2013-04-06 23:29 0x9801 阅读(130) 评论(0) 推荐(0)

httpd.conf配置错误

摘要: 无法启动Apache的原因很有可能是httpd.conf配置错误。如果apache的配置文件httpd.conf搞错了,在windows里启动它,会提示the requested operation has failed,这是比较郁闷的事,因为查错要看个半天。 其实可以用命令行模式启动apache,并带上参数,apache会提示你哪句有误,然后就可以针对性的解决。检查错误方法:进入cmd 然后进入 Apache安装目录(具体为你自己的安装目录)\bin> httpd.exe -w -n "Apache2.2" -k start 阅读全文

posted @ 2013-04-06 23:27 0x9801 阅读(239) 评论(0) 推荐(0)

Apache permission问题

摘要: don't have the permission to access on this server请将Deny from all 修改为Allow from all<Directory /> Options FollowSymLinks AllowOverride all Order deny,allow# Deny from all Allow from all</Directory> 阅读全文

posted @ 2013-04-06 23:26 0x9801 阅读(120) 评论(0) 推荐(0)

iis端口映射的配置方法

摘要: Win 7 环境1. 先在路由器配置页面的『虚拟服务器』位置进行端口映射,添加80-90端口(其实主要是下面会用到的81端口),选择ALL2. 计算机管理>> 服务和应用程序 >> Internet信息服务 >> ...>>Default Web Site找到右侧栏的『绑定』选择『添加』,类型:http,端口:81,ip : *结果如下图。 阅读全文

posted @ 2013-04-06 23:24 0x9801 阅读(2298) 评论(0) 推荐(0)

MySQL密码丢失的处理方法

摘要: 搞了两天终于把MySQL丢失root密码的事情解决掉。补写方法:cmd打开DOS命令行模式,输入net stop mysql 停掉服务;DOS模式下进入mysql的bin目录,输入mysqld --skip-grant-tables,此时程序挂起;cmd打开一个新DOS命令行,输入mysqld -uroot -p,提示输入密码时直接回车(使用空密码登录);顺利的话进入mysql命令行模式,输入下面内容:mysql> use mysql;mysql> UPDATE user SET Password = PASSWORD('TAT') WHERE user =  阅读全文

posted @ 2013-04-06 23:22 0x9801 阅读(147) 评论(0) 推荐(0)

Cg Tessellation: 曲面细分

摘要: struct C3E4_Output { float4 position : POSITION; float4 color : COLOR;};C3E4_Output C3E4v_twist(float2 position : POSITION, float4 color : COLOR, uniform float twisting){ C3E4_Output OUT; float angle = twisting * length(position); float cosLength... 阅读全文

posted @ 2013-04-06 23:17 0x9801 阅读(216) 评论(0) 推荐(0)

Cg MISC

摘要: Color interpolation: performed by the rasterization hardware smoothly shades the interior fragments of the triangle.=========================================struct C3E3f_Output { float4 color : COLOR;};C3E3f_Output C3E3f_texture(float2 texCoord : TEXCOORD0, uniform sampler2D decal){ C3E3f_Output O.. 阅读全文

posted @ 2013-04-06 23:16 0x9801 阅读(153) 评论(0) 推荐(0)

Django Template 设定某值

摘要: {% with name="World" greeting="Hello" %} <html><div>{{ greeting }} {{name}}!</div></html>{% endwith %}注意如果template有其他控制语句,有可能出现嵌套错误,例如:{% with name="D" %} {% for item in inputList %}<p><button type="submit" value="{{name}} 阅读全文

posted @ 2013-04-06 23:09 0x9801 阅读(109) 评论(0) 推荐(0)

表单提交及CSRF防护

摘要: 单的request表单提交会出现CSRF verification failed.解决方法:>>> 确保setting.py里面的MIDDLE CLASSES开启了下面项MIDDLEWARE_CLASSES = ( ... 'django.middleware.csrf.CsrfViewMiddleware', ...>>> 在Template里面表单后面加入{% csrf_token %}<form action="" method="POST">{% csrf_token %} ...& 阅读全文

posted @ 2013-04-06 22:55 0x9801 阅读(605) 评论(0) 推荐(0)

Checkbox 多重选择列表 Template

摘要: >>> check_box.html<html> <body> <p>Testing Project for OSU/CSD</p> <form action="" method="POST"> {%for item in options%} <input type="checkbox" value="1" name="check_box_list"/>{{item}} <br> {%endfo 阅读全文

posted @ 2013-04-06 22:49 0x9801 阅读(144) 评论(0) 推荐(0)

简单的django PROJECT结构及运作机理

摘要: >>> django PROJECT直观上是一个动态网站,其实可以理解为一个app的容器。┌ Project\│├──┬ mysite\│ ├── manage.py #管理引擎,用于启动服务器、检查程序、同步数据库等│ └─┬ mysite\│ ├── __init__.py│ ├── settings.py #用于管理网站的所有配置,包括数据库,资源及app安装等│ ├── urls.py #url/服务路由,管理某个url调用app下面的服务│ └── wsgi.py # Python Web Server Gateway Interface 底层工具... 阅读全文

posted @ 2013-04-06 22:46 0x9801 阅读(208) 评论(0) 推荐(0)

导航