0

Please help; I have input text data from a form into mySQL table, recovered it using php script and written it back to the form using value=var[ ]. If the data has spaces in it, i.e. more than one word, all characters after the first space are lost. But echo before the table HTML shows that the full text was recovered from the table. What's going on?

2
Contributors
4
Replies
5
Views
7 Years
Discussion Span
Last Post by Wouldbecomp
0

Hi,
Are you storing data in array after retrieving from mysql.
y?
Please try this way ans see your output-- store it as string variable.

If you have any doubt please let me know.

0

Thanks. Yes, in the php code I set a variable $x equal to the retrieved record array from the mysql table. Thereafter I used $x[columname] to get the data. echo $x[ ] gave correct full string, but input value=var[ ] was lopped.

0

Thanks. Yes, in the php code I set a variable $x equal to the retrieved record array from the mysql table. Thereafter I used $x[columname] to get the data. echo $x[ ] gave correct full string, but input value=var[ ] was lopped.

Hi Dear,
Did you get your solution.
If yes please make this thread as solved.
If not please let me know.

Thanks.

0

Dear Arunmagar
Yes thanks, the problem is now solved by putting in quotes i.e. input value ='$var[]'

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.