Guys I have two Strings
$first = "/calvin/master/?p=pages&id=3"; //DYNAMIC URL
$second = "http://localhost/calvin/"; //BASE URL USER DECIDED
I want to get full url like this
$target = "http://localhost/calvin/master/?p=pages&id=3"; //FULL URl
How can I do it.. Please note that, the directory calvin can change according to where user decides, he/she can even place script in child directories. eg. instead of calvin can be myweb/scripts/this_script
$fullURL = $second . $first;? - You'd might need to check whether the two variables contain overlapping parts, but that's a matter of regex or searching the strings.$firstand the last part of$second? like/part/is a part separated by/?calvinin$first. Will it always be same as in$second? So thathttp://localhost/calvin/becomeshttp://localhost/myweb/and/calvin/master/?p=pages&id=3becomes/myweb/master/?p=pages&id=3. Or?