简体   繁体   中英

How to use urlencode to handle two question marks in url in php

I have tried to understand and use urlencode, but the problem can't be solved.

The code is:
<?php print 'index.php/?page=search?query='.quote_replace(addmarks($search_results['did_you_mean'])).'&search=1'?>

use urlencode

edit

try rawurlencode

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM