安装Nginx和php
sudo apt-get update #更新源
sudo apt-get install php7.3 php7.3-fpm php7.3-mysql php7.3-common
sudo apt-get install nginx
sudo service nginx start #重启nginx
sudo service php7.3-fpm restart #重启php
安装Nginx和php
sudo apt-get update #更新源
sudo apt-get install php7.3 php7.3-fpm php7.3-mysql php7.3-common
sudo apt-get install nginx
sudo service nginx start #重启nginx
sudo service php7.3-fpm restart #重启php
从网上看看了一些php下载文件的资料,改了改,写了这么个函数.
1. 开启防火墙端口:/sbin/iptables -I INPUT -p tcp --dport 80 -j ACCEPT/sbin/iptables -I INPUT -p tcp --dport 22822 -j ACCEPT/sbin/iptables -I INPUT -p tcp --dport 2121 -j ACCEPT/sbin/iptables -I INPUT -p tcp --dport 3306 -j ACCEPT/etc/rc.d/init.d/iptables save/etc/init.d/iptables restart查看...
在运行时必须知道某个变量为何值。
然后在php.ini中设置:include_path = "c:/php",并将debug.php放在此文件夹,以后就可以在每个网页里包含此文件,查看得到的变量名和值.
function delhtml($content){ $content = eregi_replace("<html>.+</head>","", $content); $content = preg_replace("/<.+?>/i","", $content); return $content; } $oneurl = "http://www.chenapp.com"; $content = file_get_contents($oneurl); echo delhtml($content);