I built a page sometime back and have a value called $quote.
Someone asked me to add some stuff to it and added a class to help make some urls for me.
here's the class:
Class Url
{
function get_url($data)
{
for($i=0; $i<count($data); $i++)
{
$newdata .= "$data[$i]";
$i++;
$newdata .= "=$data[$i]&";
}
$newdata = str_replace(" ", "%20", $newdata);
return $newdata;
}
}
$data is passed in as an arry like
$data = array("quote", "$quote") or however you desire.
as the function is building the url it builds ="e=$quote
This poses a problem, because when the function passes back the url it interprets the "e as a " (quotation mark)
Is there a way to stop this?