deansaddigh Posted April 6, 2010 Share Posted April 6, 2010 All im doing is making a form txt area and passing in a variable as a value echo '<textarea name="question" value="'.$row['question'].'"/>'; Thanks in advance Link to comment https://forums.phpfreaks.com/topic/197752-whats-wrong-with-this/ Share on other sites More sharing options...
aeroswat Posted April 6, 2010 Share Posted April 6, 2010 All im doing is making a form txt area and passing in a variable as a value echo '<textarea name="question" value="'.$row['question'].'"/>'; Thanks in advance What kind of error are u getting? Link to comment https://forums.phpfreaks.com/topic/197752-whats-wrong-with-this/#findComment-1037778 Share on other sites More sharing options...
deansaddigh Posted April 6, 2010 Author Share Posted April 6, 2010 ive changed it to this echo '<textarea name="question" value="'.$row['question'].'"></textarea>'; its just not displaying anything in the text area. full code is <?php $query = "SELECT * FROM faq WHERE faq_id =$id"; $result = mysql_query($query, $conn) or die('Error, query failed'); while($row= mysql_fetch_array($result)) { echo '<input type="text" SIZE="50" name="question" value="'.$row['question'].'"/>'; echo '<textarea name="question" value="'.$row['question'].'"></textarea>'; } ?> Link to comment https://forums.phpfreaks.com/topic/197752-whats-wrong-with-this/#findComment-1037780 Share on other sites More sharing options...
aeroswat Posted April 6, 2010 Share Posted April 6, 2010 textarea html tag does not use value to display like a textbox does. echo '<textarea name="question" value="'.$row['question'].'"></textarea>'; should be echo '<textarea name="question">'.$row['question'].'</textarea>'; Link to comment https://forums.phpfreaks.com/topic/197752-whats-wrong-with-this/#findComment-1037781 Share on other sites More sharing options...
deansaddigh Posted April 6, 2010 Author Share Posted April 6, 2010 Thank you so much, i appreciate you taking the time to help me out Link to comment https://forums.phpfreaks.com/topic/197752-whats-wrong-with-this/#findComment-1037782 Share on other sites More sharing options...
aeroswat Posted April 6, 2010 Share Posted April 6, 2010 Thank you so much, i appreciate you taking the time to help me out Np bro Good luck to ya Link to comment https://forums.phpfreaks.com/topic/197752-whats-wrong-with-this/#findComment-1037792 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.