Trouble displaying info in a multiline form
| From: | Paulo Nunes | Date: | Tue, 04 Jun 2002 18:51:00 +0000 |
| Subject: | Trouble displaying info in a multiline form | ||
| Groups: | php.db | ||
| Request: | Send a blank email to php-db+get-19606@lists.php.net to get a copy of this message | ||
Hi all
I'm having trouble displaying some content into a multiline form. Some part
of the field's data seems to be missing. I'm using the following code:
<?php
$query = "select * from sections where id='".$sectionid."'";
$result = pg_exec( $db , $query );
$r = pg_fetch_row($result, 0);
$description = $r[1];
$button_text = $r[3];
$content = ' '.$r[4].' ';
$visible = $r[5];
echo "<p><B>Section: ".$r[0]."<B></p>";
echo "<FORM action=\"updatesite.php?
op=section§ionid=$sectionid&sessionid=$sessionid\" method=POST>";
echo "<P>Description <br><input length=50 type=text
name=\"description\"
value='$description' > </P>";
echo "<P>Button text: <br><input length=20 type=text
name=\"button_text\"
value='$button_text' > </P>";
echo "<P>Contents: <br><textarea length =8000 cols=50 rows=20
name=\"content\" value=".\
$content." > </textarea></P>";
echo "<P><input type =submit value =\"Gravar\"></P>";
echo "</FORM>";
The variable $content should contain the correct data, but it cuts a part of
the beggining and some part of the end. I think it has nothing to do with
the fields size.
Can anyone help me with this?
If it helps, i'm using php3 and postgresql6
Thank in advance
Paulo Nunes