how do you increase the height of an html textbox

后端 未结 8 1064
野性不改
野性不改 2020-12-24 04:53

How do you increase the height of an textbox? (along with its font size)

相关标签:
8条回答
  • 2020-12-24 05:37

    I'm assuming from the way you worded the question that you want to change the size after the page has rendered?

    In Javascript, you can manipulate DOM CSS properties, for example:

    document.getElementById('textboxid').style.height="200px";
    document.getElementById('textboxid').style.fontSize="14pt";
    

    If you simply want to specify the height and font size, use CSS or style attributes, e.g.

    //in your CSS file or <style> tag
    #textboxid
    {
        height:200px;
        font-size:14pt;
    }
    
    <!--in your HTML-->
    <input id="textboxid" ...>
    

    Or

    <input style="height:200px;font-size:14pt;" .....>
    
    0 讨论(0)
  • 2020-12-24 05:38

    Don't the height and font-size CSS properties work for you ?

    0 讨论(0)
提交回复
热议问题