I am trying to prefill a form with a string from a mysql table. Problem is if the string contains spaces only the text before the first space is displayed in the text box.
Any way to solve this other than using <textarea>?
I experimented with urlencode/urldecode: urlencode($row["surfaceCondition"]); displays complete string with "+" inserted for spaces.
urldecode(urlencode($row["surfaceCondition"])); truncates string as above.
Code Snippet:
$result = mysql_query("select * from snowReport");
$row = mysql_fetch_array($result);
return $row;
<form>
<input type=text name=surfaceCondition size=20 maxlength=150 value=<? echo $row["surfaceCondition"]); ?>>
</form.