The forums have permanently moved to This forum will be kept around in read-only mode for archival purposes. To learn how to continue using your existing account on the new forums, check out this thread.

Results 1 to 2 of 2

Thread: filling textarea with php variable

  1. #1

    filling textarea with php variable

    I'm trying to create an update form for blog entries and to populate the form i have it all working except for the text area because there is no value= for textareas. here is the php code.
    PHP Code:

    $id $_GET['b_id'];

    $query "SELECT * FROM blog WHERE b_id = $id";
    $resultmysql_query($query) or die(mysql_error());

    '<form action="new_blog.php" method="post">
        <p>Title: <input type="text" name="title" value="'
    .$row[1].'" size="30" maxlength="200"/> </p>
        <p>Location:<input type="text" name="location" value="'
    .$row[2].'" size="30" height="40"> </p>
        <p>Entry: <textarea wrap="virtual"name="entry" cols="75"rows="10"maxlength="100">'
    .$row[3].'</textarea> </p>
        <p>Map Point: <input type="text" name="b_locpoints" value="'
    .$row[5].'"size="4" maxlength="3"/> </p>

        <p><input type="submit" name="submit" value="Submit" /></p>
        <input type="hidden" name="submitted" value="TRUE" />
        <input type="hidden" name"id" value="'

    everything else echo out fine but the text area keeps giving me errors such as
    Parse error: parse error, unexpected T_VARIABLE, expecting ',' or ';' in .... on line17

  2. #2
    Never mind, fixed it

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Home About Meet the Moderators Advertise

 Link to Us


Copyright 1999 - 2012