Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to set text size in a button in html

Hello I want to have a button on my website and I want to resize the text on my button. How do I do this?

My code is below:

<input type="submit" value="HOME" onclick="goHome()" style="width: 100%; height: 100px;"/>  
like image 902
Pancake_Senpai Avatar asked Aug 19 '13 09:08

Pancake_Senpai


People also ask

How do I change the size of the text inside a button?

To change the font size of a button, use the font-size property.

How do I change the font of a button in HTML?

To change font size in HTML, use the CSS font-size property. Set it to the value you want and place it inside a style attribute. Then add this style attribute to an HTML element, like a paragraph, heading, button, or span tag.

How do I change the text style of a button?

To select multiple button objects, click the first object, then press and hold the CTRL key while you click the other objects. Click the Style ribbon. Use the controls in the Text Style group to change the text style of a button object as follows: Click this to select a text style to apply to the objects.

Can you style a button in HTML?

A style attribute on a <button> tag assigns a unique style to the button. Its value is CSS that defines the appearance of the button.


1 Answers

Try this

<input type="submit"         value="HOME"         onclick="goHome()"         style="font-size : 20px; width: 100%; height: 100px;" />  
like image 139
Devang Rathod Avatar answered Sep 21 '22 22:09

Devang Rathod