来源:http://www.nowamagic.net/librarys/veda/detail/1250
重点:
Object.prototype.toString.call(arr)==='[object Array]'
来源:http://www.nowamagic.net/librarys/veda/detail/1250
重点:
Object.prototype.toString.call(arr)==='[object Array]'
在phpmyadmin中执行下列语句: CREATE TABLE `message` ( `id` tinyint(1) NOT NULL auto_increment, `user` varchar(25) NOT NULL, `title` varchar(50) NOT NULL, `content` tinytext NOT NULL, `lastdate` date NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=gbk AUTO_INCREMENT=1 ; 问题:phpmyadmin报错——Unknown storage engine 'InnoDB' 解决方法:解决方法: 1.关闭MySQL数据库 2.修改my.ini文件,把skip-innodb这行注释掉 3.打开MySQL数据库 当然把innodb改成MyISAM也行
var arr = [[1, 2, 3], [7, 2, 3], [3, 2, 3]]; arr.sort(function(x, y){ //return x[key].localeCompare(y[key]);//中文可以用这个 return x[0] – y[0]; });
function is_mobile() { $user_agent = $_SERVER ['HTTP_USER_AGENT']; $mobile_browser = Array ( "mqqbrowser", // 手机QQ浏览器 "opera mobi", // 手机opera "juc", "iuc", // uc浏览器 "fennec", "ios", "applewebKit/420", "applewebkit/525", "applewebkit/532", "ipad", "iphone", "ipaq", "ipod", "iemobile", "windows ce", // windows phone "240×320", "480×640", "acer", "android", "anywhereyougo.com", "asus", "audio", "blackberry", "blazer", "coolpad", "dopod", "etouch", "hitachi", "htc", "huawei", "jbrowser", "lenovo", "lg", "lg-", "lge-", "lge", "mobi", "moto", "nokia", "phone", "samsung", "sony", "symbian", "tablet", "tianyu", "wap", "xda", "xde", "zte" ); $is_mobile = false; foreach ( $mobile_browser as $device ) { if (stristr ( $user_agent, $device )) { $is_mobile = true; break; } } return $is_mobile; }