php - Replace %26 with ampersand -


every piece of research refers replacing ampersand %26, when in fact want replace %26 in url ampersand.

at moment each time pass url under command %26 back.

for example code passing in form follows

    <form method="get" action="<?php echo $server['php_self'];?>">      <input type="text" id="stg" name="stg" size = "25" value="<?php echo '?pn=' . $sub1 .'%26'.$jrny.'&subject='.$subject.'&pn2='.$sub1. '&arc='.$sess.'&table_id='.$table_id; ;?>" /> 

when try string replace or rawurlencode functions still end %26. doing wrong?

thanks

you can use urldecode function:

print_r(urldecode ( "%26" )); 

will print out:

& 

Comments

Popular posts from this blog

java - WARN : org.springframework.web.servlet.PageNotFound - No mapping found for HTTP request with URI [/board/] in DispatcherServlet with name 'appServlet' -

android - How to create dynamically Fragment pager adapter -

1111. appearing after print sequence - php -