摘要:
实现效果:类似1234567890-->1,234,567,890。代码://未考虑浮点型/* * method 1 * echo number_format($str,2,'.',','); */ /* method2 * 先反转字符串strrev 再str_split($str,3); $str = strrev($str); $arr = str_split($str,3);//987 $res = ''; $count = count($arr); whil... 阅读全文
摘要:
无需多言,直接上代码,高度超过时自动显示滚动条,不超过高度时隐藏滚动条。<!DOCTYPE html><html><head><meta charset=utf-8 /><title>JS Bin</title><style> article, aside, figure, footer, header, hgroup, menu, nav, section { display: block; }</style></head><body><div id="di 阅读全文