Eugene, Thank You much!!!! :) I really appreciate it!!! Will
PS: I am curious on other guys and gals would do this code.
Eugene Lee wrote:
On Sat, Oct 18, 2003 at 01:27:05AM -0400, Will wrote:
: : Thanks for the code but it comes up a parse error. I know I am new, but : this is driving me crazy!!! :(
: Here is the code that I am working with:
: : $display_block = "
: <form method=\"POST\" action=\"do_note_modify.php\">
: <input type=\"hidden\" name=\"notes_id\" value=\"$_POST[notes_id]\">
: <input type=\"hidden\" name=\"care_id\" value=\"$care_id\">
: <input type=\"hidden\" name=\"common\" value=\"$common\">
: <input type=\"hidden\" name=\"notes\">
: : <p><b>||Cage No.: <font color=\"#ff0000\">$care_id</font> | Common Name: : <font color=\"#ff0000\">$common</font>||</b></p>
: : <p><b>Date:</b><br>
: <input type=\"text\" name=\"date\" value=\"$date\" size=\"40\"></p>
: : echo "<p><b>Notes:</b><br>\n
: <textarea rows=5 cols=31 name=\"notes\" wrap=virtual>" . : htmlentities($notes) . "</textarea></p>\n";
: : <p><input type=\"submit\" name=\"submit\" value=\"Modify This Note\"></p>
: </form>";
: : I know it does not look right, can I take out the "echo", or must that : stay??
Why not make life easier and use a heredoc?
$htmlnotes = htmlentities($notes); $display_block = <<<BLOCK <form method="POST" action="do_note_modify.php"> <input type="hidden" name="notes_id" value="$_POST[notes_id]"> <input type="hidden" name="care_id" value="$care_id"> <input type="hidden" name="common" value="$common"> <input type="hidden" name="notes"> <p><b>||Cage No.: <font color="#ff0000">$care_id</font> | Common Name: <font color="#ff0000">$common</font>||</b></p> <p><b>Date:</b><br> <input type="text" name="date" value="$date" size="40"></p> <p><b>Notes:</b><br> <textarea rows=5 cols=31 name="notes" wrap=virtual>$htmlnotes</textarea></p> <p><input type="submit" name="submit" value="Modify This Note"></p> </form> BLOCK;
echo $display_block;
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php