質問編集履歴

1

「該当のソースコード」にcssの読み込みコードを記述

2017/08/15 02:10

投稿

shiroikoma
shiroikoma

スコア38

test CHANGED
File without changes
test CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  wordpressで自分用の独自テーマを作ろうとしています。
4
4
 
5
- javascriptファイルを読み込みたいです。
5
+ javascriptファイル/cssファイルを読み込みたいです。
6
6
 
7
7
 
8
8
 
@@ -14,7 +14,9 @@
14
14
 
15
15
  テーマのトップに文字列として記述されてしまう。
16
16
 
17
- ・fanction.phpに下記のコードを記述しているとcssも読み込まれなくな
17
+ ・fanction.phpに下記のコードを記述してからcssも読み込まれなくなった
18
+
19
+ (削除しても改善されず…)
18
20
 
19
21
 
20
22
 
@@ -25,6 +27,14 @@
25
27
  function test() { wp_enqueue_script('myscript', get_template_directory_uri().'/js/move.js'); } add_action('wp_enqueue_scripts', 'test');
26
28
 
27
29
  ```
30
+
31
+ ```css読み込み
32
+
33
+ <link rel="stylesheet" href="<?php get_stylesheet_uri(); ?>">
34
+
35
+ ```
36
+
37
+
28
38
 
29
39
 
30
40