PHP人民币金额大写转换类

PHP人民币金额大写转换类

class Num2Cny{ static $basical = array(0=>"零","壹","贰","叁","肆","伍","陆","柒","捌","玖"); static $advanced=array(1=>"拾","佰","仟"); public static function ParseNumber($number){$number=trim($number); if ($number>999999999999) return "数字太大,无法处理。抱歉!"; if ($number==0) return "零&quo...

PHP 2019-12-11 PM 2966℃ 0条
PHP 获取当前浏览器类型

PHP 获取当前浏览器类型

/**获取当前浏览器类型@return [type] [description] */function my_get_browser(){ if(empty($_SERVER['HTTP_USER_AGENT'])){ return 'robot!'; } if( (false == strpos($_SERVER['HTTP_USER_AGENT'],'MSIE')) && (strpos($_SERVER['HTTP_USER_AGENT'], 'Trident')!==FALSE) ){ return 'Internet Explorer 11.0'; ...

PHP 2019-12-11 PM 2789℃ 0条
ESP32进入wifi的STA和AP混合模式进行配网(micropython环境)

ESP32进入wifi的STA和AP混合模式进行配网(micropython环境)

使ESP32进入wifi的STA和AP混合模式进行配网(micropython环境) 我们在用ESP32做开发时,由于初始化配网的需要,往往是需要工作在AP模式,但是也要能使用STA模式的扫描功能,列出周围可用的wifi热点列表,方便用户通过选择的方式输入热点名。这就需要进入STA和AP的混合模式。 但是,在micropython的标准文档中,wifi的模式只有STA和AP两种模式,似乎没有混合模式。并且STA模式和AP模式的切换很容易出现扫描不到周围的wifi热点、wifi模块报unknown error 0x0102错误导致wifi模块失效等问题。 为此,笔者经过...

MicroPython 2019-12-11 PM 6555℃ 0条
js 强制跳转https

js 强制跳转https

var matchStr =window.location.href; var reURL = /^(https):\/\/.+$/; if(!reURL.test(matchStr)){ window.location.href = "https://www.1231818.com/"; }

前端 2019-12-02 AM 4804℃ 0条
js 判断客户端自动跳转

js 判断客户端自动跳转

方法1: try { if (location.search.indexOf('?pc') !== 0 && /Android|Windows Phone|iPhone|iPod/i.test(navigator.userAgent)) { window.location.href = 'https://xw.qq.com?f=qqcom'; } } catch (e) {} 方法2: var sUserAgent = navigator.userAgent, mobileAgents = ['Windows CE', 'iPod'...

前端 2019-12-02 AM 3986℃ 0条
jQuery+AJAX+PHP+MySQL数据库开发搜索功能,无跳转无刷新搜索

jQuery+AJAX+PHP+MySQL数据库开发搜索功能,无跳转无刷新搜索

index.html<!DOCTYPE html><meta charset="utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <title>AJAX搜索</title> <style type="text/css"> *{margin:0px;padding:0px;} h2{ text-align: center; } ...

PHP 2019-11-09 PM 3737℃ 0条
ajax ,jquery,php实现查找并更新显示数据

ajax ,jquery,php实现查找并更新显示数据

<!DOCTYPE html><head> <meta charset="UTF-8"> <title></title> <script type="text/javascript" src="js/jquery.min.js"></script> <script> $(function() { $("#name").on("keyup&q...

PHP 2019-11-09 PM 2545℃ 0条
php AJAX 查询

php AJAX 查询

function showResult(str) { if (str.length==0) { document.getElementById("livesearch").innerHTML=""; document.getElementById("livesearch").style.border="0px"; return; } if (window.XMLHttpRequest) {// IE7+, Firefox, Chrome, Opera, Safari 浏览器执行 x...

PHP 2019-11-09 PM 2530℃ 0条
PHP自动调取在线壁纸作为网站背景

PHP自动调取在线壁纸作为网站背景

<?php/*功能:自动调取壁纸作为网站背景开发时间:2017年7月4日应用案例:https://www.68xi.cn/search/分享三个在线壁纸调用接口tags http://cdn.apc.360.cn/index.php?c=WallPaper&a=getAllCategoriesV2&from=360chromenew http://wallpaper.apc.360.cn/index.php?c=WallPaper&a=getAppsByOrder&order=create_time&start=【0开始】&count=【加载数】&from=360chrome专区 ...

PHP 2019-11-05 AM 2896℃ 0条
PHP POST传递参数

PHP POST传递参数

<?phpheader("Content-type: text/html; charset=utf-8"); $name = 'wd='.$_GET['name']; $html = (string)request_by_curl('http://yongjiuzy.net/index.php?m=vod-search',$name); $a = '/<td class=\".*\"><a href=\"(.*)\" .*>(.*)<font color=\".*\">...

PHP 2019-11-05 AM 4382℃ 0条
PHP爬虫 获取 Bilibili 视频封面图

PHP爬虫 获取 Bilibili 视频封面图

<?phpfunction curl($url){$ch = curl_init(); curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 5000); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt($ch, CURLOPT_HTTPHEADER, array('User-Agent: Mozilla/5.0 (iPhone; CPU iPhone OS 8_0 like Mac OS X) AppleWebKit/600.1.3 (KHTML, like Gecko) Version...

PHP 2019-11-05 AM 3215℃ 0条