Jump to content


Photo

How show Text field type


  • Please log in to reply
3 replies to this topic

#1 nestorvaldez

nestorvaldez
  • Members
  • PipPip
  • Member
  • 12 posts

Posted 28 September 2006 - 07:11 PM

Hi
I have a Text Type Field in Mysql.. I can save the data but If want to show it in a select or retrieve to update I can't get it. I can't see the data I've saved in the table. How can I do this?

#2 alpine

alpine
  • Members
  • PipPipPip
  • Advanced Member
  • 756 posts
  • LocationNorway

Posted 28 September 2006 - 07:19 PM

please post your current code

#3 nestorvaldez

nestorvaldez
  • Members
  • PipPip
  • Member
  • 12 posts

Posted 28 September 2006 - 09:04 PM

$id = $_GET['id'];
$query = mysql_query("SELECT per_mensaje FROM `personal` WHERE PER_ID='$id'");
$row = mysql_fetch_array($query);

$mensaje = $row['per_mensaje'];

<td><textarea name="mensaje" cols="40" rows="10" class="tabla" id="textarea3" tabindex="16"  value="<?php echo("$mensaje");?>"></textarea></td>


PS: The PER_MENSAJE field is a TEXT type.

#4 alpine

alpine
  • Members
  • PipPipPip
  • Advanced Member
  • 756 posts
  • LocationNorway

Posted 28 September 2006 - 09:20 PM

I think it is within the textarea tag you have the error, it should be

<textarea name="mensaje" cols="40" rows="10" class="tabla" id="textarea3" tabindex="16"><?php echo $mensaje; ?></textarea>






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users