作者:蓝逸
日期:2023-04-12
分类:编程
浏览:216℃
评论:0条
squid要说是一个神级别的软件,其他的代理和反向代理都是弟弟 ```c https_port 443 accel defaultsite=mywebsite.mydomain.com \ cert=/path/to/wildcardPublicKeyCert.pem \ key=/path/to/wildcardPrivateKeyCert.pem # First (HTTP) peer cache_peer 10.112.62.20 parent 80 0 no-query originserver login=PASS name=websiteA acl sites_server_1 ...
作者:蓝逸
日期:2023-04-12
分类:编程
浏览:206℃
评论:0条
有垃圾带宽的可以测试下 wget --no-check-certificate https://github.com/teddysun/across/raw/master/bbr.sh && chmod +x bbr.sh && ./bbr.sh ...
作者:蓝逸
日期:2023-04-12
分类:编程
浏览:212℃
评论:0条
nginx 拦截非法字符,nginx禁止url访问特定字符,nginx过滤url访问 参考代码一 #前缀为无限,后面的精准屏蔽字符 123 if ($request_uri ~* "123") { return 403 "I've recorded your ip Wait to check the water meter"; } 参考代码二 #前缀为index.php,后面的精准屏蔽字符 123 #资源宝分享:www.httple.net if ($request_uri ~* "/index.php\123") { return 403 "I've recorded your ip Wai...
作者:蓝逸
日期:2023-04-12
分类:编程
浏览:274℃
评论:0条
DD网络重装脚本 腾讯云删除监控组件 41合一脚本(可DD windows) 宝塔面板7.7.0 常用脚本 综合工具箱(强烈推荐,集成了很多脚本) 一键开启BBR(适用于较新的Debian、Ubuntu) superbench Bench.sh 三网测速 yabs 机器跑分 一键安装docker 国外 国内 卸载docker 流媒体测试 全媒体测试 奈飞测试 不太常用脚本 杜甫测试 单线程测试 直接显示回程线路 测试25端口是否开放 一键修改默认SSH端口,自行替换2222 一键清理 /var/log/目录下的过期日志 测试IPv4优先还是IPv6优先 目前用过的最好用,功能最全的套warp...
作者:蓝逸
日期:2023-04-12
分类:编程
浏览:214℃
评论:0条
下面是一段简单的 PHP 代码,可以将数据写入文本文件中: // 定义要写入文本文件的数据 $data = "这是要写入文本文件的数据"; // 使用 fopen() 函数打开文件,如果文件不存在则创建它 $file = fopen("data.txt", "w"); // 使用 fwrite() 函数写入数据 fwrite($file, $data); // 关闭文件 fclose($file); 在上面的代码中,我们首先定义了要写入文件的数据,然后使用fopen()函数打开了一个名为data.txt的文件,并使用w模式打开,这表示如果文件不存在,会创建一个新文件。然后,我们使用fwrit...
作者:蓝逸
日期:2023-04-12
分类:编程
浏览:214℃
评论:0条
下面是一个简单的 PHP 程序,用于生成静态 HTML 文件: $content = "This is a static HTML file"; // 将内容写入文件 file_put_contents("index.html", $content); 在这个程序中,我们首先定义了一个变量$content,并将其赋值为一个包含 HTML 标记的字符串。然后,我们使用 PHP 的file_put_contents()函数,将该字符串写入一个名为index.html的文件中。 请注意,上面的程序只是一个示例,实际的应用中可能会有更复杂的逻辑。但是,这个程序展示了如何使用 PHP 来生成静态 HT...
作者:蓝逸
日期:2023-04-12
分类:编程
浏览:249℃
评论:0条
下面是一个简单的 PHP 程序,用于递归地建立文件夹和文件: // 定义要建立的文件夹和文件的路径 $folderPath = "./my_folder"; $filePath = "./my_folder/my_file.txt"; // 建立文件夹 if (!is_dir($folderPath)) { mkdir($folderPath, 0777, true); } // 建立文件 if (!file_exists($filePath)) { touch($filePath); } 在这个程序中,我们首先定义了要建立的文件夹和文件的路径。然后,我们使用 PHP 的is_dir()函数...
作者:蓝逸
日期:2023-04-12
分类:编程
浏览:204℃
评论:0条
在PHP中,可以使用函数php_strip_whitespace()来实现对PHP代码的加密。该函数会删除PHP源文件中的所有注释和空白字符,并将剩余的代码进行压缩,使其更难被人阅读。下面是一段示例代码,可用于对PHP代码进行加密: <?php // Set the name of the PHP file to encrypt $filename = "myfile.php"; // Read the PHP file into a string $source = file_get_contents($filename); // Strip whitespace and comme...
作者:蓝逸
日期:2023-04-12
分类:编程
浏览:204℃
评论:0条
在PHP中,可以使用文本文件来实现简单的留言板功能。下面是一段示例PHP代码,可用于实现此功能: <?php // Set the name of the text file that will store the messages $filename = "messages.txt"; // Check if the form was submitted if (isset($_POST['submit'])) { // Read the name and message from the form $name = $_POST['name']; $message = $_POST[...
作者:蓝逸
日期:2023-04-12
分类:编程
浏览:203℃
评论:0条
<?php // Set the name of the text file that will store the news items $filename = "news.txt"; // Check if the form was submitted if (isset($_POST['submit'])) { // Read the title and body from the form $title = $_POST['title']; $body = $_POST['body']; // Append the title and body to the news file...