thinkphp等系统专用,url传递的参数不能带有/等特殊字符
function base_encode($str) { $src = array("/","+","=","?","&"); $dist = array("_.a._","_.b._","_.c._","_.d._","_.e._"); $new = str_replace($src,$dist,$str); return $new; } function base_decode($str) { $src = array("_.a._","_.b._","_.c._","_.d._","_.e._"); $dist = array("/","+","=","?","&"); $new = str_replace($src,$dist,$str); return $new; }
以上就是自定义url变量转义方法的内容,更多相关内容请关注PHP中文网(www.php.cn)!

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

Atom editor mac version download
The most popular open source editor

MinGW - Minimalist GNU for Windows
This project is in the process of being migrated to osdn.net/projects/mingw, you can continue to follow us there. MinGW: A native Windows port of the GNU Compiler Collection (GCC), freely distributable import libraries and header files for building native Windows applications; includes extensions to the MSVC runtime to support C99 functionality. All MinGW software can run on 64-bit Windows platforms.

EditPlus Chinese cracked version
Small size, syntax highlighting, does not support code prompt function

Dreamweaver Mac version
Visual web development tools

Notepad++7.3.1
Easy-to-use and free code editor