質問するログイン新規登録

質問編集履歴

1

cssのコードを追加、現象のssを追加

2019/06/12 10:00

投稿

kondoh
kondoh

スコア10

title CHANGED
File without changes
body CHANGED
@@ -1,6 +1,6 @@
1
- ### 前提・実現したいこと
1
+ ![イメージ説明]### 前提・実現したいこと
2
2
 
3
- html及びcssでHP作成しています。
3
+ html及びcssを練習しています。
4
4
  そこで<h>を使用した際中の文字が中央によってしまいます。
5
5
 
6
6
  ### 発生している問題・エラーメッセージ
@@ -14,8 +14,53 @@
14
14
  ### 該当のソースコード
15
15
 
16
16
  ```ここに言語名を入力
17
+ <html>
18
+ <!DOCTYPE html>
19
+ <html>
20
+ <head>
21
+ <meta charset="utf-8">
22
+ <title>Progate</title>
23
+ <link rel="stylesheet" href="stylesheet.css">
24
+ </head>
25
+ <body>
26
+ <!-- ここからHTMLを書き始めてください -->
27
+ <div class="header">
28
+ <h1 class="header-title">Progate</h1>
29
+ <ul>
30
+ <li>プログラミングとは</li>
31
+ <li>学べるレッスン</li>
32
+ <li>お問い合わせ</li>
33
+
34
+ </ul>
35
+ </div>
36
+
37
+ <div class="main">
38
+ <h1>HELLOWORLD<span>.</span></h1>
39
+ <h2>プログラミングの世界へようこそ</h2>
40
+
41
+
42
+ <div class="contents">
43
+ <h3 class="contents-title">学べるレッスン</h3>
44
+ <div class="contents-pic">
45
+ <img src="https://s3-ap-northeast-1.amazonaws.com/progate/shared/images/lesson/html/study/html.svg" alt="" />
46
+ <p class="contents-mokuji">HTML</p>
47
+ </div>
48
+ <div class="contents-pic">
49
+ <img src="https://s3-ap-northeast-1.amazonaws.com/progate/shared/images/lesson/html/study/php.svg" alt="" />
50
+ <p class="contents-mokuji">PHP</p>
51
+ </div>
52
+ <div class="contents-pic">
53
+ <img src="https://s3-ap-northeast-1.amazonaws.com/progate/shared/images/lesson/html/study/ruby.svg" alt="" />
54
+ <p class="contents-mokuji">Ruby</p>
55
+ </div>
56
+ <div class="contents-pic">
57
+ <img src="https://s3-ap-northeast-1.amazonaws.com/progate/shared/images/lesson/html/study/swift.svg" alt="" />
58
+ <p class="contents-mokuji">Swift</p>
59
+ </div>
60
+ </div>
61
+
17
- <div class="form">
62
+ <div class="form">
18
- <h4 class="contents-title">お問い合わせ</h4>
63
+ <h4 class="form-title">お問い合わせ</h4>
19
64
  <p class="contents-list">メールアドレス(必須)</p>
20
65
  <input>
21
66
  <p class="contents-list">お問い合わせ内容(必須)</p>
@@ -24,6 +69,127 @@
24
69
  <input class="button" type="submit" value="送信">
25
70
 
26
71
  </div>
72
+
73
+
74
+ </div>
75
+
76
+ </body>
77
+ </html>
78
+
79
+ <css>
80
+ /* CSSのリセット(消さないでください) */
81
+ html, body,
82
+ ul, ol, li,
83
+ h1, h2, h3, h4, h5, h6, p,
84
+ form, input, div {
85
+ margin: 0;
86
+ padding: 0;
87
+ }
88
+
89
+ li {
90
+ list-style: none;
91
+ }
92
+
93
+ body{
94
+ font-family:"Avenir Next","Hiragino Kaku Gothic ProN W3",sans-serif;
95
+ }
96
+
97
+ /* ここからCSSを記述してください */
98
+
99
+ .header{
100
+ background-color:#26d0c9;
101
+ height:90px;
102
+ color:white;
103
+ }
104
+
105
+ .header-title{
106
+ font-size:36px;
107
+ padding:20px 40px;
108
+ float:left;
109
+
110
+ }
111
+
112
+ .header li{
113
+ float:left;
114
+ font-size:20px;
115
+ padding:33px 20px;
116
+ }
117
+
118
+ .main{
119
+ float:left;
120
+ padding-left:80px;
121
+ }
122
+
123
+ .main h1{
124
+ font-size:140px;
125
+ padding-top:100px;
126
+
127
+ }
128
+
129
+ .main span{
130
+ color:red;
131
+ }
132
+
133
+ .main h2{
134
+ font-size:60px;
135
+ }
136
+
137
+ .contents{
138
+ height:500px;
139
+ }
140
+
141
+ .contents-title{
142
+ font-size:28px;
143
+ padding-top:100px;
144
+ padding-bottom:15px;
145
+ border-bottom:solid 2px #dee7ec;
146
+ margin-bottom:50px;
147
+
148
+ }
149
+
150
+ .contents-pic{
151
+ float:left;
152
+ padding-right:40px;
153
+ }
154
+
155
+ .contents-mokuji{
156
+ padding-top:30px;
157
+ font-size:24px;
158
+ padding-bottom:100px;
159
+ }
160
+
161
+ .form{
162
+ margin-bottom:100px;
163
+
164
+ }
165
+
166
+ .form-title{
167
+ font-size:28px;
168
+ padding-top:100px;
169
+ padding-bottom:15px;
170
+ border-bottom:solid 2px #dee7ec;
171
+ margin-bottom:50px;
172
+
173
+ }
174
+
175
+
176
+ input,textarea{
177
+ padding:20px;
178
+ margin-bottom:30px;
179
+ width:400px;
180
+ border:1px #dee7ec solid;
181
+ }
182
+
183
+ .contents-list{
184
+ margin-bottom:10px;
185
+ }
186
+
187
+ .button{
188
+ color:#889ead;
189
+ font-size:18px;
190
+ background-color:#dee7ec;
191
+ }
192
+
27
193
  ```
28
194
 
29
195
  ### 試したこと
@@ -33,4 +199,4 @@
33
199
 
34
200
  ### 補足情報(FW/ツールのバージョンなど)
35
201
 
36
- ここにより詳細な情報を記載してください。
202
+ ![イメージ説明](7e18ffaa031625e334077f81860db20b.png)