如何利用 CentOS 进行端口转发TCP+UDP协议转发开启NATfirewall-cmd --add-masquerade --permanent添加转发1.开放TCP端口转发(本机端口31002转发到 10.0.1.2:3389)firewall-cmd --add-forward-port=port=31002:proto=tcp:toport=3389:toaddr=10.0.1.2 --permanent2.开放UDP端口转发(本机端口31002转发到 10.0.1.2:3389)firewall-cmd --add-forward-port=port=31002:proto...
jquery判断手机端或者pc端<script> $(function(){ if(navigator.userAgent.match(/mobile/i)) { alert('手机') }else { alert('pc') } }); </script>
AAAJS隐藏和显示div的方式有两种:方式1:隐藏后释放占用的页面空间通过设置display属性可以使div隐藏后释放占用的页面空间.style="display: none;" document.getElementById("demo").style.display="none";//隐藏 document.getElementById("demo").style.display="";//显示 方式2:隐藏后仍占有页面空间,显示空白div的visibility可以控制div的显示和...
centos firewall-cmd防火墙设置增加一条富规则:firewall-cmd --permanent --add-rich-rule='rule family="ipv4" source address="202.106.86.130" port port="3306" protocol="tcp" accept'firewall-cmd --reload删除一条富规则:firewall-cmd --permanent --remove-rich-rule='rule family="ipv4" source address="202.106.86.130" port por...
Linux通过防火墙禁止IP来防止攻击iptables -I INPUT -s 211.1.0.0 -j DROP 禁止211.1.0.0这个IP访问服务器iptables -I INPUT -s 211.1.0.0 -j ACCEPT 允许211.1.0.0这个IP访问服务器iptables -nv -L 查看所有iptables策略iptables -F 清空所有规则
@font-face { font-family: YOUSHEhaoshenti; /*自定义的字体名称*/ src: url("./YOUSHEhaoshenti.ttf"); /*引入字体包*/ } body{ font-family: YOUSHEhaoshenti; }
01 尾数不是4的 \d+[^4]$ 02 不能含4的 [0-35-9]{11} 03 AABB尾号 ^\d+(\d)(?!\1)(\d)\2((?!\2)\d)\3$ 04 AAA尾号 ^\d+(\d)(?!\1)(\d)\2{2}$ 05 AAA非尾号 ^(\d)+(?!\1)(\d)\2{2}(?!\2)\d+$ 06 AAA不限位 ^(\d)+(?!\1)(\d)\2{2}(?!\2)\d*$ 07 AAAB尾号 (\d)+(?!\1)(\d)\2{2}((?!\2)\d)$ 08 ABAB...
golang中base64编码和解码golang中base64的编码和解码可以用内置库encoding/base64package main import ( "encoding/base64" "fmt" "log" ) func main() { input := []byte("hello golang base64 快乐编程http://www.01happy.com +~") // 演示base64编码 encodeString := ba...
golang中匹配手机号码,主要还是写出匹配的表达式。package main import ( "fmt" "regexp" ) func main() { reg := `^1([38][0-9]|14[57]|5[^4])\d{8}$` rgx := regexp.MustCompile(reg) s := []string{"18505921256", "13489594009", "12759029321"} for _, ...
$shieldid=make_safe($_POST["shieldid"]);//转换数组------------ //屏蔽单号------------$names = explode("\n", $shieldid); foreach($names as $val){if($val!="" || $val!=" "){ $arr[] =str_replace(array("\r\n", "\r", "\n"), "", $val); //这里必须药过滤下}}/...