in order to pass names from page to page via get but i have problems!
I succeded running first this code:
їcode]$loc=ereg_replace(" ","+",$loc);ї/code]
but when i use
їcode]$plus='+';
$loc=ereg_replace($plus, " ",$loc);ї/code]
or
$loc=ereg_replace("+", " ",$loc);
i get this error:
Warning: Invalid preceding regular expression in /home/greeceqt.com/www/locations_islands.php on line 15
What is wrong?I guess that the problem is + which may be confused with its operator ability!
Can't replace + with ereg_replace
Moderator: General Moderators
try
Code: Select all
$loc=ereg_replace("\+", " ",$loc);OK it worked! I also found thatWayne wrote:tryCode: Select all
$loc=ereg_replace("\+", " ",$loc);
Code: Select all
$loc=str_replace("+", " ",$loc);