#1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Nov 2012
    Posts
    24
    Rep Power
    0

    Form textarea dimension


    Is it possible to change the width and height of textarea.If means please tell me how to do that.
    The following is my code.
    PHP Code:
    <tr>

                <
    td>
                
    Question<font color="red">*</font>
                </
    td>
               <
    td><textarea name="ques1" id="ques1" cols="25" rows="5" style="resize:none;"></textarea>
                </
    td>
                <
    td>
                    <
    table>
                    <
    tr>
                    <
    td width="10">
                    <
    div style="background-image:url(img/mic1_30.jpg); width:30px; height:25px;" >
                    <
    input type="file" id="quest_wav1" name="quest_wav1"  style="opacity:0;-moz-opacity:0 ;filter:alpha(opacity: 0);" size="1"  />
                    </
    div>
                    </
    td>
                    </
    tr>
                    <
    tr>
                    <
    td width="10">
                    <
    div style="background-image:url(img/img1.jpeg); width:30px; height:30px;" >
                    <
    input type="file" id="quest_img1" name="quest_img1"  style="opacity:0;-moz-opacity:0 ;filter:alpha(opacity: 0);" size="1"   />
                    </
    div>
                    </
    td>
                    </
    tr>
                    </
    table>
                </
    td>
                </
    tr>
            <
    tr>
                <
    td>Page No<font color="red">*</font></td><td>:</td>
                <
    td><input type="text" name="pno" id="pno"  size="16" /></td>
                <
    td>Chapter No<font color="red">*</font></td><td>:</td>
                <
    td><input type="text" name="cno" id="cno" size="16"  ></td>
                </
    tr
    Please tell me i've to increase the size of textarea for the question field only. Please tell me how to do that.
  2. #2
  3. Sarcky
    Devshed Supreme Being (6500+ posts)

    Join Date
    Oct 2006
    Location
    Pennsylvania, USA
    Posts
    10,908
    Rep Power
    6352
    This has nothing to do with PHP, this is an HTML question.

    Textareas have rows and cols. You already have those attributes in your code. Make them bigger.
    HEY! YOU! Read the New User Guide and Forum Rules

    "They that can give up essential liberty to obtain a little temporary safety deserve neither liberty nor safety." -Benjamin Franklin

    "The greatest tragedy of this changing society is that people who never knew what it was like before will simply assume that this is the way things are supposed to be." -2600 Magazine, Fall 2002

    Think we're being rude? Maybe you asked a bad question or you're a Help Vampire. Trying to argue intelligently? Please read this.
  4. #3
  5. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Nov 2012
    Posts
    24
    Rep Power
    0
    Sorry for posting in php.
    Actually all the fields are inside one table. So by increasing the size or rows and cols attribute,all other fields move aside in a form.So is there any other option in table tag for doing this. Please tell me.
  6. #4
  7. Sarcky
    Devshed Supreme Being (6500+ posts)

    Join Date
    Oct 2006
    Location
    Pennsylvania, USA
    Posts
    10,908
    Rep Power
    6352
    The <td> tag has a "colspan" attribute that determines how many columns it takes up in the resulting table.

    However, you have tables within tables here, and you're using tables for layout. The proper solution is to read up on how to use DIVs for layout so you don't run into table-based spacing issues like this one.

    I did a quick google search and this article doesn't look half bad.
    HEY! YOU! Read the New User Guide and Forum Rules

    "They that can give up essential liberty to obtain a little temporary safety deserve neither liberty nor safety." -Benjamin Franklin

    "The greatest tragedy of this changing society is that people who never knew what it was like before will simply assume that this is the way things are supposed to be." -2600 Magazine, Fall 2002

    Think we're being rude? Maybe you asked a bad question or you're a Help Vampire. Trying to argue intelligently? Please read this.

IMN logo majestic logo threadwatch logo seochat tools logo