In my form I have the following values that are based on a standard PHP/MySql query.
echo \"\\n
Locati
-
You forgot quotes :
echo "<tr>\n
<td align='right'><b>Location</b></td>
<td><input name='student_location' type='text' size='25' style='font-weight: 700' value=\"$location\"></td>
</tr>";
Without quotes, the first word will be noted, others will be interpreted as wrong attributes.
讨论(0)
-
you need to quote it by escaping the "
echo "<tr>\n
<td align='right'><b>Location</b></td>
<td><input name='student_location' type='text' size='25' style='font-weight: 700' value=\"$location\"></td>
</tr>";
讨论(0)
-
You need to put your single quotes around it to make it a valid attribute. The HTML is being created as value=North Campus
which gets interpreted as value="North"
and some Campus
attribute that has no value. Use value='$location'
.
讨论(0)
- 热议问题