skymvc开发手册之函数库
skymvc函数库位于skymvc/function/
function.php /**skymvc程序使用情况**/ skyTest(); /**写入日志**/ skyLog($file,$content) /**根据\n转数组**/ nrexplode($str) /**根据空格转数组**/ texplode($str) //获取小数点 numdot($str) //sql参数转义 sql($value) /*$_GET $_POST *$format="i/f/h/s/x/r/a" * i--intval * f--floatval * h--htmlspecialchars * s--strip_tags * x--nRemoveXSS * r--round * a--all */ get($k,$format="",$len) post($k,$format="",$len=0) get_post($k,$format="",$len=0) /**将数组元素格式化成类似 '1','2','3' 的字符串***/ _implode($array) /****截取字符串函数****/ cutstr($string, $length, $dot = ' ...') /*移除链接*/ removelink($c) /**加密**/ umd5($str) /***获取内容的图片***/ getImgs($content,$i=9999) /***替换远程图片*****/ replaceImgs($content) /****字符串转JS*****/ strToJs($content) /***获取Ip****/ ip() /***get内容******/ curl_get_contents($url,$timeout=30) /***post内容*****/ curl_post($url, $data) /***post json****/ curl_post_json($url, $json) /****判断是否来自搜索引擎*****/ is_robot() /****判断是否邮件*****/ is_email($email) /****判断是否手机号码******/ is_tel($telephone) /*是否来自手机*/ is_mobile() /***加密***/ jiami($str) /****解密***/ jiemi($str)