Ask Your Question
1

How can I display only the name and hide the button and text input box?

asked 2022-05-16 11:00:00 +0000

lalupa gravatar image

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2023-02-07 02:00:00 +0000

qstack gravatar image

You can do this by setting the CSS display property of the button and input elements to "none". For example, if your HTML code is like this:

<label for="name">Name:</label>
<input type="text" id="name" name="name">
<button type="submit">Submit</button>

You can add this CSS code to hide the button and input elements:

button, input[type="text"] {
  display: none;
}

This will hide the button and input box, leaving only the label and its text visible on the page.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account. This space is reserved only for answers. If you would like to engage in a discussion, please instead post a comment under the question or an answer that you would like to discuss

Add Answer


Question Tools

Stats

Asked: 2022-05-16 11:00:00 +0000

Seen: 20 times

Last updated: Feb 07 '23