質問編集履歴

4

試したこと追加

2023/05/04 07:52

投稿

fullmoon311
fullmoon311

スコア62

test CHANGED
File without changes
test CHANGED
@@ -111,7 +111,10 @@
111
111
  ```
112
112
  ### 試したこと
113
113
 
114
- chrome検証ツールを見たところ、該当jsファイルありません。
114
+ ウィジェットを入れ替えたことにより、cssIDが自動的に変わっ影響いうとが分かったですIDを変更しても動作しませんでした
115
+
116
+
117
+
115
118
 
116
119
  ### 補足情報(FW/ツールのバージョンなど)
117
120
 

3

コンソールにエラーが出ていました。

2023/05/04 07:21

投稿

fullmoon311
fullmoon311

スコア62

test CHANGED
File without changes
test CHANGED
@@ -25,6 +25,12 @@
25
25
 
26
26
  ```
27
27
  エラーメッセージ
28
+
29
+ uery.Deferred exception: Cannot read properties of undefined (reading 'top') TypeError: Cannot read properties of undefined (reading 'top')
30
+ at objOffset (https://xxxx.jp/wp-content/themes/xxxx/js/app.js?ver=1683177113:447:20)
31
+ at HTMLDocument.<anonymous> (https://xxxx.jp/wp-content/themes/xxxx/js/app.js?ver=1683177113:415:17)
32
+ at e (https://xxxx.jp/wp-includes/js/jquery/jquery.min.js:2:30038)
33
+ at t (https://xxxx.jp/wp-includes/js/jquery/jquery.min.js:2:30340) undefine
28
34
  ```
29
35
 
30
36
  ### 該当のソースコード

2

変更

2023/05/04 06:44

投稿

fullmoon311
fullmoon311

スコア62

test CHANGED
File without changes
test CHANGED
@@ -30,7 +30,14 @@
30
30
  ### 該当のソースコード
31
31
 
32
32
  ```functions.php
33
+ functions.phpの冒頭でactionフックしています。
34
+
35
+ function bzbsk_temp_wp_enqueue_scripts()
36
+ {
37
+ wp_enqueue_style('parent-style', get_template_directory_uri() . '/style.css'); //cssファイルの場合
33
- wp_enqueue_script('app', get_stylesheet_directory_uri() . '/js/app.js', array('jquery'));
38
+ wp_enqueue_script('app', get_stylesheet_directory_uri() . '/js/app.js', array('jquery'));
39
+ }
40
+ add_action('wp_enqueue_scripts', 'bzbsk_temp_wp_enqueue_scripts');
34
41
  ```
35
42
 
36
43
  ```app.js

1

確認事項追加

2023/05/04 06:39

投稿

fullmoon311
fullmoon311

スコア62

test CHANGED
File without changes
test CHANGED
@@ -98,7 +98,7 @@
98
98
  ```
99
99
  ### 試したこと
100
100
 
101
- ここに問題に対して試したことを記載してください
101
+ chromeの検証ツールを見ろ、該当のjsファイルがありません
102
102
 
103
103
  ### 補足情報(FW/ツールのバージョンなど)
104
104