質問編集履歴

3

コメントのエラーについても追記しました。

2019/04/17 14:50

投稿

maricos
maricos

スコア13

test CHANGED
File without changes
test CHANGED
@@ -14,6 +14,10 @@
14
14
 
15
15
 
16
16
 
17
+ ####サイドバーが表示されない。
18
+
19
+
20
+
17
21
  個別の記事ページにおいて、ページ上部に表示されるワードプレスツールバーとサイドバーが表示されなくなりました。恐らくこの記事を更新した直後ではないかと思います。
18
22
 
19
23
  https://vwp789171.kagoyacloud.com/2019/04/03/line-pay/
@@ -22,6 +26,14 @@
22
26
 
23
27
 
24
28
 
29
+ ####コメントができない
30
+
31
+
32
+
33
+ コメントボタンを押しても何も起きません。
34
+
35
+
36
+
25
37
  ### 試したこと
26
38
 
27
39
 

2

single-contents.phpの中身を追記しました。

2019/04/17 14:50

投稿

maricos
maricos

スコア13

test CHANGED
File without changes
test CHANGED
@@ -165,3 +165,119 @@
165
165
 
166
166
 
167
167
  <?php get_footer(); ?>
168
+
169
+
170
+
171
+ single-contents.phpの中身
172
+
173
+ ----------
174
+
175
+ <?php
176
+
177
+ /**
178
+
179
+ * Cocoon WordPress Theme
180
+
181
+ * @author: yhira
182
+
183
+ * @link: https://wp-cocoon.com/
184
+
185
+ * @license: http://www.gnu.org/licenses/gpl-2.0.html GPL v2 or later
186
+
187
+ */
188
+
189
+ if ( !defined( 'ABSPATH' ) ) exit;
190
+
191
+
192
+
193
+ ///////////////////////////////////////
194
+
195
+ // 投稿ページのコンテンツ
196
+
197
+ ///////////////////////////////////////?>
198
+
199
+ <?php //パンくずリストがメイントップの場合
200
+
201
+ if (is_single_breadcrumbs_position_main_top()){
202
+
203
+ get_template_part('tmp/breadcrumbs');
204
+
205
+ } ?>
206
+
207
+
208
+
209
+ <?php //本文テンプレート
210
+
211
+ get_template_part('tmp/content') ?>
212
+
213
+
214
+
215
+
216
+
217
+ <div class="under-entry-content">
218
+
219
+ <?php get_template_part('tmp/related-entries'); //関連記事 ?>
220
+
221
+
222
+
223
+ <?php //関連記事下の広告表示
224
+
225
+ if (is_ad_pos_below_related_posts_visible() && is_all_adsenses_visible()){
226
+
227
+ get_template_part_with_ad_format(get_ad_pos_below_related_posts_format(), 'ad-below-related-posts', is_ad_pos_below_related_posts_label_visible());
228
+
229
+ }; ?>
230
+
231
+
232
+
233
+ <?php //投稿関連記事下ウイジェット
234
+
235
+ if ( is_active_sidebar( 'below-single-related-entries' ) ): ?>
236
+
237
+ <?php dynamic_sidebar( 'below-single-related-entries' ); ?>
238
+
239
+ <?php endif; ?>
240
+
241
+
242
+
243
+ <?php get_template_part('tmp/pager-post-navi'); //投稿ナビ ?>
244
+
245
+
246
+
247
+ <?php //コメントを表示する場合
248
+
249
+ if (is_single_comment_visible()) {
250
+
251
+ comments_template(); //コメントテンプレート
252
+
253
+ } ?>
254
+
255
+
256
+
257
+ <?php //コメントフォーム下ウイジェット
258
+
259
+ if ( is_active_sidebar( 'below-single-comment-form' ) ): ?>
260
+
261
+ <?php dynamic_sidebar( 'below-single-comment-form' ); ?>
262
+
263
+ <?php endif; ?>
264
+
265
+
266
+
267
+ </div>
268
+
269
+
270
+
271
+ <?php //パンくずリストがメインボトムの場合
272
+
273
+ if (is_single_breadcrumbs_position_main_bottom()){
274
+
275
+ get_template_part('tmp/breadcrumbs');
276
+
277
+ } ?>
278
+
279
+
280
+
281
+ <?php //メインカラム追従領域
282
+
283
+ get_template_part('tmp/main-scroll'); ?>

1

single.phpの中身を追記しました。

2019/04/17 14:48

投稿

maricos
maricos

スコア13

test CHANGED
File without changes
test CHANGED
@@ -115,3 +115,53 @@
115
115
 
116
116
 
117
117
  利用中のプラグイン:
118
+
119
+
120
+
121
+ single.phpの中身
122
+
123
+ ---------
124
+
125
+ <?php //通常ページとAMPページの切り分け
126
+
127
+ /**
128
+
129
+ * Cocoon WordPress Theme
130
+
131
+ * @author: yhira
132
+
133
+ * @link: https://wp-cocoon.com/
134
+
135
+ * @license: http://www.gnu.org/licenses/gpl-2.0.html GPL v2 or later
136
+
137
+ */
138
+
139
+ if ( !defined( 'ABSPATH' ) ) exit;
140
+
141
+
142
+
143
+ if (!is_amp()) {
144
+
145
+ get_header();
146
+
147
+ } else {
148
+
149
+ get_template_part('tmp/amp-header');
150
+
151
+ }
152
+
153
+ ?>
154
+
155
+
156
+
157
+ <?php //投稿ページ内容
158
+
159
+ get_template_part('tmp/single-contents'); ?>
160
+
161
+
162
+
163
+ <h2><?php the_field('title'); ?></h2>
164
+
165
+
166
+
167
+ <?php get_footer(); ?>