在根目录下的index.php前面加上以下这段代码即可;if(preg_match("/zh-cn/is",$_SERVER['HTTP_ACCEPT_LANGUAGE'])){ header("HTTP/1.1 404 Not Found"); header("Status: 404 Not Fo...
分类:
其他好文 时间:
2014-08-07 12:18:39
阅读次数:
185
<?php
header(‘Content-Type:text/html;charset=utf-8‘);
functioncutstr($str,$len){
if($len<0){returnnull;}
$chars=0;//字符数量
$offset=0;
$res=‘‘;
while($chars<$len){
$high=decbin(ord(substr($str,$offset,1)));
if(strlen($high)<8){
$count=1;
}els..
分类:
Web程序 时间:
2014-08-07 07:39:10
阅读次数:
265
modal是Bootstrap提供的一个“窗口组件”,可以配合js实现弹出窗口的效果。modal的class是“modal”,其中必须包含三个div部分,属性分别问modal-header,modal-body,modal-footer.同时modal可以用来放置注册表单,示例如下:[html] v...
分类:
其他好文 时间:
2014-08-06 18:47:11
阅读次数:
317
前段时间,Insus.NET一直在演示GridView控件Header头行或列:《动态变更GridView控件列名》和《动态合并或定制GridView控件Header头某些列》,现今想演示合并Gridview的DataRow中的列。其实合并列也不是什么复杂的问题,只想明白其中的原理,就觉得简单至极。...
分类:
其他好文 时间:
2014-08-06 17:29:21
阅读次数:
197
通过判断访问来源来实现。$fromurl="http://www.111.com/index.php"; //只能从这个地址访问if( $_SERVER['HTTP_REFERER'] != $fromurl ){ header("Location:".$fromurl); exit;}不好...
分类:
Web程序 时间:
2014-08-06 11:49:21
阅读次数:
308
8月5日,第一个项目即将完成,测试时,发现登录功能会出现小问题:记住密码的时候会报错Warning: Cannot modify header information - headers already sent by (output started at经过再三在百度上查询,终于查到错误的关键原因...
分类:
其他好文 时间:
2014-08-05 22:15:40
阅读次数:
195
UICollectionView 和 UICollectionViewController 类是iOS6 新引进的API,用于展示集合视图,布局更加灵活,可实现多列布局,用法类似于UITableView 和 UITableViewController 类与UICollectionView有关的三个协...
分类:
其他好文 时间:
2014-08-05 22:07:20
阅读次数:
200
.shortcut ul li { display: inline; }CSS View CodeHeader ...
分类:
Web程序 时间:
2014-08-05 18:41:30
阅读次数:
361
HTTP Header中Accept-Encoding 是浏览器发给服务器,声明浏览器支持的编码类型[1]常见的有Accept-Encoding: compress, gzip //支持compress 和gzip类型Accept-Encoding: //默认是identityAccept-Enco...
分类:
其他好文 时间:
2014-08-05 10:57:29
阅读次数:
208
一、下载任意文件: Header("Content-type: application/octet-stream"); $ua = $_SERVER["HTTP_USER_AGENT"]; $encoded_filename = rawurlencode($fil...
分类:
Web程序 时间:
2014-08-04 20:53:47
阅读次数:
628