Computer >> 컴퓨터 >  >> 프로그램 작성 >> CSS

CSS로 스타일 입력 유형 제출

<시간/>

입력 유형 버튼은 제출 버튼 또는 재설정 버튼일 수 있습니다. CSS를 사용하면 웹페이지의 모든 버튼에 스타일을 지정할 수 있습니다.

다음 코드를 실행하여 입력 유형 제출의 스타일을 지정할 수 있습니다.

<!DOCTYPE html>
<html>
   <head>
      <style>
         input[type = submit] {
            background-color: orange;
            border: none;
            text-decoration: none;
            color: white;
            padding: 20px 20px;
            margin: 20px 20px;
            cursor: pointer;
         }
      </style>
   </head>
   <body>
      <p>Fill the below form,</p>
      <form>
         <label for = "subject">Subject</label>
         <input type = "text" id="subject" name  ="sub"><br><br>
         <label for = "student">Student</label>
         <input type = "text" id = "student" name = "stu"><br>
         <input type = "submit" value = "Submit">
      </form>
   </body>
</html>