回答編集履歴
4
追記
test
CHANGED
@@ -3,10 +3,6 @@
|
|
3
3
|
|
4
4
|
|
5
5
|
type="image/x-icon" にすると良さそうです
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
追記+修正 09/29 20:51
|
10
6
|
|
11
7
|
|
12
8
|
|
@@ -69,3 +65,65 @@
|
|
69
65
|
<link rel="icon" href="https://teratail.com/favicon.ico">
|
70
66
|
|
71
67
|
```
|
68
|
+
|
69
|
+
さらに追記 下記コードのみのhtmlファイルを作成して試してみてください。
|
70
|
+
|
71
|
+
```html
|
72
|
+
|
73
|
+
<!DOCTYPE html>
|
74
|
+
|
75
|
+
<html lang="en">
|
76
|
+
|
77
|
+
|
78
|
+
|
79
|
+
<head>
|
80
|
+
|
81
|
+
<meta charset="UTF-8">
|
82
|
+
|
83
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
84
|
+
|
85
|
+
<link rel="apple-touch-icon-precomposed" size="72x72"
|
86
|
+
|
87
|
+
href="https://teratail.com/img/favicon/apple-touch-icon-72x72-precomposed.png">
|
88
|
+
|
89
|
+
<link rel="apple-touch-icon-precomposed" size="114x114"
|
90
|
+
|
91
|
+
href="https://teratail.com/img/favicon/apple-touch-icon-114x114-precomposed.png">
|
92
|
+
|
93
|
+
<link rel="apple-touch-icon-precomposed" size="144x144"
|
94
|
+
|
95
|
+
href="https://teratail.com/img/favicon/apple-touch-icon-144x144-precomposed.png">
|
96
|
+
|
97
|
+
<link rel="apple-touch-icon-precomposed" size="152x152"
|
98
|
+
|
99
|
+
href="https://teratail.com/img/favicon/apple-touch-icon-152x152-precomposed.png">
|
100
|
+
|
101
|
+
<link rel="apple-touch-icon-precomposed" size="180x180"
|
102
|
+
|
103
|
+
href="https://teratail.com/img/favicon/apple-touch-icon-180x180-precomposed.png">
|
104
|
+
|
105
|
+
<link rel="icon" type="image/png" sizes="32x32" href="https://teratail.com/img/favicon/favicon-32x32.png">
|
106
|
+
|
107
|
+
<link rel="icon" type="image/png" sizes="16x16" href="https://teratail.com/img/favicon/favicon-16x16.png">
|
108
|
+
|
109
|
+
<link rel="mask-icon" href="https://teratail.com/img/favicon/safari-pinned-tab.svg" color="#f4c51c">
|
110
|
+
|
111
|
+
<link rel="icon" href="https://teratail.com/favicon.ico">
|
112
|
+
|
113
|
+
<title>Document</title>
|
114
|
+
|
115
|
+
</head>
|
116
|
+
|
117
|
+
|
118
|
+
|
119
|
+
<body>
|
120
|
+
|
121
|
+
|
122
|
+
|
123
|
+
</body>
|
124
|
+
|
125
|
+
|
126
|
+
|
127
|
+
</html>
|
128
|
+
|
129
|
+
```
|
3
追記+修正
test
CHANGED
@@ -6,7 +6,9 @@
|
|
6
6
|
|
7
7
|
|
8
8
|
|
9
|
-
追記
|
9
|
+
追記+修正 09/29 20:51
|
10
|
+
|
11
|
+
|
10
12
|
|
11
13
|
```html
|
12
14
|
|
@@ -44,30 +46,26 @@
|
|
44
46
|
|
45
47
|
下記のteratail.comのファビコンに関する記述が参考になると思います。
|
46
48
|
|
47
|
-
直リンクになるため念のため href="tps としております。
|
48
|
-
|
49
|
-
正しくはhref="httpsです。
|
50
|
-
|
51
49
|
|
52
50
|
|
53
51
|
```html
|
54
52
|
|
55
53
|
<link rel="apple-touch-icon-precomposed" size="72x72" href="https://teratail.com/img/favicon/apple-touch-icon-72x72-precomposed.png">
|
56
54
|
|
57
|
-
<link rel="apple-touch-icon-precomposed" size="114x114" href="tps://teratail.com/img/favicon/apple-touch-icon-114x114-precomposed.png">
|
55
|
+
<link rel="apple-touch-icon-precomposed" size="114x114" href="https://teratail.com/img/favicon/apple-touch-icon-114x114-precomposed.png">
|
58
56
|
|
59
|
-
<link rel="apple-touch-icon-precomposed" size="144x144" href="tps://teratail.com/img/favicon/apple-touch-icon-144x144-precomposed.png">
|
57
|
+
<link rel="apple-touch-icon-precomposed" size="144x144" href="https://teratail.com/img/favicon/apple-touch-icon-144x144-precomposed.png">
|
60
58
|
|
61
|
-
<link rel="apple-touch-icon-precomposed" size="152x152" href="tps://teratail.com/img/favicon/apple-touch-icon-152x152-precomposed.png">
|
59
|
+
<link rel="apple-touch-icon-precomposed" size="152x152" href="https://teratail.com/img/favicon/apple-touch-icon-152x152-precomposed.png">
|
62
60
|
|
63
|
-
<link rel="apple-touch-icon-precomposed" size="180x180" href="tps://teratail.com/img/favicon/apple-touch-icon-180x180-precomposed.png">
|
61
|
+
<link rel="apple-touch-icon-precomposed" size="180x180" href="https://teratail.com/img/favicon/apple-touch-icon-180x180-precomposed.png">
|
64
62
|
|
65
|
-
<link rel="icon" type="image/png" sizes="32x32" href="tps://teratail.com/img/favicon/favicon-32x32.png">
|
63
|
+
<link rel="icon" type="image/png" sizes="32x32" href="https://teratail.com/img/favicon/favicon-32x32.png">
|
66
64
|
|
67
|
-
<link rel="icon" type="image/png" sizes="16x16" href="tps://teratail.com/img/favicon/favicon-16x16.png">
|
65
|
+
<link rel="icon" type="image/png" sizes="16x16" href="https://teratail.com/img/favicon/favicon-16x16.png">
|
68
66
|
|
69
|
-
<link rel="mask-icon" href="tps://teratail.com/img/favicon/safari-pinned-tab.svg" color="#f4c51c">
|
67
|
+
<link rel="mask-icon" href="https://teratail.com/img/favicon/safari-pinned-tab.svg" color="#f4c51c">
|
70
68
|
|
71
|
-
<link rel="icon" href="tps://teratail.com/favicon.ico">
|
69
|
+
<link rel="icon" href="https://teratail.com/favicon.ico">
|
72
70
|
|
73
71
|
```
|
2
コード変更
test
CHANGED
@@ -52,7 +52,7 @@
|
|
52
52
|
|
53
53
|
```html
|
54
54
|
|
55
|
-
<link rel="apple-touch-icon-precomposed" size="72x72" href="tps://teratail.com/img/favicon/apple-touch-icon-72x72-precomposed.png">
|
55
|
+
<link rel="apple-touch-icon-precomposed" size="72x72" href="https://teratail.com/img/favicon/apple-touch-icon-72x72-precomposed.png">
|
56
56
|
|
57
57
|
<link rel="apple-touch-icon-precomposed" size="114x114" href="tps://teratail.com/img/favicon/apple-touch-icon-114x114-precomposed.png">
|
58
58
|
|
1
回答の編集
test
CHANGED
@@ -3,3 +3,71 @@
|
|
3
3
|
|
4
4
|
|
5
5
|
type="image/x-icon" にすると良さそうです
|
6
|
+
|
7
|
+
|
8
|
+
|
9
|
+
追記
|
10
|
+
|
11
|
+
```html
|
12
|
+
|
13
|
+
<!--アイコン指定-->
|
14
|
+
|
15
|
+
<link rel="icon" type="image/x-icon" href="favicon.ico">
|
16
|
+
|
17
|
+
<!--アイコン指定スマホ用-->
|
18
|
+
|
19
|
+
<link rel="apple-touch-icon" sizes="180x180" href="apple-touch-icon-180x180.png">
|
20
|
+
|
21
|
+
```
|
22
|
+
|
23
|
+
上記コードを記載したhtmlをサーバー上にアップロードし
|
24
|
+
|
25
|
+
ファビコンの表示を確認しました。
|
26
|
+
|
27
|
+
|
28
|
+
|
29
|
+
macのsafari、chrome、firefox
|
30
|
+
|
31
|
+
androidのchrome
|
32
|
+
|
33
|
+
iphone11のsafari
|
34
|
+
|
35
|
+
|
36
|
+
|
37
|
+
上記コードだけで大半のデバイスでファビコンが表示されると思いますが、
|
38
|
+
|
39
|
+
デバイスによって表示されないこともあるようです。
|
40
|
+
|
41
|
+
|
42
|
+
|
43
|
+
teratailでファビコンが表示されるのでしたら
|
44
|
+
|
45
|
+
下記のteratail.comのファビコンに関する記述が参考になると思います。
|
46
|
+
|
47
|
+
直リンクになるため念のため href="tps としております。
|
48
|
+
|
49
|
+
正しくはhref="httpsです。
|
50
|
+
|
51
|
+
|
52
|
+
|
53
|
+
```html
|
54
|
+
|
55
|
+
<link rel="apple-touch-icon-precomposed" size="72x72" href="tps://teratail.com/img/favicon/apple-touch-icon-72x72-precomposed.png">
|
56
|
+
|
57
|
+
<link rel="apple-touch-icon-precomposed" size="114x114" href="tps://teratail.com/img/favicon/apple-touch-icon-114x114-precomposed.png">
|
58
|
+
|
59
|
+
<link rel="apple-touch-icon-precomposed" size="144x144" href="tps://teratail.com/img/favicon/apple-touch-icon-144x144-precomposed.png">
|
60
|
+
|
61
|
+
<link rel="apple-touch-icon-precomposed" size="152x152" href="tps://teratail.com/img/favicon/apple-touch-icon-152x152-precomposed.png">
|
62
|
+
|
63
|
+
<link rel="apple-touch-icon-precomposed" size="180x180" href="tps://teratail.com/img/favicon/apple-touch-icon-180x180-precomposed.png">
|
64
|
+
|
65
|
+
<link rel="icon" type="image/png" sizes="32x32" href="tps://teratail.com/img/favicon/favicon-32x32.png">
|
66
|
+
|
67
|
+
<link rel="icon" type="image/png" sizes="16x16" href="tps://teratail.com/img/favicon/favicon-16x16.png">
|
68
|
+
|
69
|
+
<link rel="mask-icon" href="tps://teratail.com/img/favicon/safari-pinned-tab.svg" color="#f4c51c">
|
70
|
+
|
71
|
+
<link rel="icon" href="tps://teratail.com/favicon.ico">
|
72
|
+
|
73
|
+
```
|