<?php $search_html = filter_input(INPUT_GET, 'search', FILTER_SANITIZE_SPECIAL_CHARS); $search_url = filter_input(INPUT_GET, 'search', FILTER_SANITIZE_ENCODED); echo "You have searched for $search_html.\n"; echo "<a href='?search=$search_url'>Search again.</a>"; ?>
一开始不懂 search 为什么是字符串,后面看了手册才知道是变量名的意思,这里直接不加$了
标签:again,Search,函数,search,filter,input From: https://www.cnblogs.com/BreakLAC/p/17115989.html