How to show php content in textarea?

Discussion in 'PHP' started by ere34, Nov 16, 2010.

  1. #1
    how can i show a PHP variable in a textarea?
     
    ere34, Nov 16, 2010 IP
  2. imocoder

    imocoder Member

    Messages:
    45
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    43
    #2
    Create a file and add this code:

    
    $variable_name = "Some text ...";
    <form method="post" action="" style="margin:0px">
    <textarea name="" rows="4" cols="44"><?php echo $variable_name;?></textarea>
    </form>
    
    Code (markup):
    "Some text ..." will appear in the textarea.
     
    imocoder, Nov 16, 2010 IP
  3. Ankurkr

    Ankurkr Peon

    Messages:
    14
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    I am also looking for that type of script . this script will help me lot in completion of my future project. thanks a lot
     
    Ankurkr, Nov 17, 2010 IP