質問編集履歴
2
誤
test
CHANGED
File without changes
|
test
CHANGED
@@ -48,214 +48,194 @@
|
|
48
48
|
|
49
49
|
</div>
|
50
50
|
|
51
|
-
|
52
|
-
|
53
|
-
<
|
54
|
-
|
55
|
-
<!
|
56
|
-
|
57
|
-
<
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
51
|
+
|
52
|
+
|
53
|
+
<?php if( !is_front_page() ): ?>
|
54
|
+
|
55
|
+
<?php if( !is_front_page() ): ?>
|
56
|
+
|
57
|
+
<!--ぱんくず -->
|
58
|
+
|
59
|
+
<section id="breadcrumb">
|
60
|
+
|
61
|
+
<ol itemscope itemtype="http://schema.org/BreadcrumbList">
|
62
|
+
|
63
|
+
<li itemprop="itemListElement" itemscope
|
64
|
+
|
65
|
+
itemtype="http://schema.org/ListItem"><a href="<?php echo home_url(); ?>" itemprop="item"><span itemprop="name">HOME</span></a> > <meta itemprop="position" content="1" /></li>
|
66
|
+
|
67
|
+
<?php
|
68
|
+
|
69
|
+
$i = 2;
|
70
|
+
|
71
|
+
foreach ( array_reverse( get_post_ancestors( $post->ID ) ) as $parid ) { ?>
|
72
|
+
|
73
|
+
|
74
|
+
|
75
|
+
<li itemprop="itemListElement" itemscope
|
76
|
+
|
77
|
+
itemtype="http://schema.org/ListItem"><a href="<?php echo get_page_link( $parid ); ?>" title="<?php echo get_the_title(); ?>" itemprop="item"> <span itemprop="name"><?php echo get_page( $parid )->post_title; ?></span></a> > <meta itemprop="position" content="<?php echo $i; ?>" /></li>
|
78
|
+
|
79
|
+
<?php $i++; } ?>
|
80
|
+
|
81
|
+
</ol>
|
82
|
+
|
83
|
+
</section>
|
84
|
+
|
85
|
+
<!--/ ぱんくず -->
|
86
|
+
|
87
|
+
<?php endif; ?>
|
88
|
+
|
89
|
+
|
90
|
+
|
91
|
+
<div id="st-page" <?php post_class('post'); ?>>
|
92
|
+
|
93
|
+
<article>
|
94
|
+
|
95
|
+
<!--ループ開始 -->
|
96
|
+
|
97
|
+
<?php if (have_posts()) : while (have_posts()) :
|
98
|
+
|
99
|
+
the_post(); ?>
|
100
|
+
|
101
|
+
|
102
|
+
|
103
|
+
<?php if(!is_front_page()){ ?>
|
104
|
+
|
105
|
+
<h1 class="entry-title"><?php the_title(); //タイトル ?></h1>
|
106
|
+
|
107
|
+
<?php } ?>
|
108
|
+
|
109
|
+
|
110
|
+
|
111
|
+
<div class="mainbox">
|
112
|
+
|
113
|
+
|
114
|
+
|
115
|
+
<div class="entry-content">
|
116
|
+
|
117
|
+
<?php the_content(); //本文 ?>
|
118
|
+
|
119
|
+
</div>
|
120
|
+
|
121
|
+
|
122
|
+
|
123
|
+
<?php //ページ改
|
124
|
+
|
125
|
+
$defaults = array(
|
126
|
+
|
127
|
+
'before' => '<p class="tuzukicenter"><span class="tuzuki">' . __( '', 'default' ),
|
128
|
+
|
129
|
+
'after' => '</span></p>',
|
130
|
+
|
131
|
+
'link_before' => '> ',
|
132
|
+
|
133
|
+
'link_after' => ' ',
|
134
|
+
|
135
|
+
'next_or_number' => 'next',
|
136
|
+
|
137
|
+
'separator' => ' ',
|
138
|
+
|
139
|
+
'nextpagelink' => __( '続きを読む', 'default' ),
|
140
|
+
|
141
|
+
'previouspagelink' => __( '前のページへ', 'default' ),
|
142
|
+
|
143
|
+
'pagelink' => '%',
|
144
|
+
|
145
|
+
'echo' => 1
|
146
|
+
|
147
|
+
);
|
148
|
+
|
149
|
+
wp_link_pages( $defaults );
|
150
|
+
|
151
|
+
?>
|
152
|
+
|
153
|
+
|
154
|
+
|
155
|
+
</div>
|
156
|
+
|
157
|
+
|
158
|
+
|
159
|
+
<?php if( is_front_page() ):
|
160
|
+
|
161
|
+
get_template_part( 'sns-top' ); //トップ用ソーシャルボタン読み込み
|
162
|
+
|
163
|
+
else:
|
164
|
+
|
165
|
+
get_template_part( 'sns' ); //ページ用ソーシャルボタン読み込み
|
166
|
+
|
167
|
+
endif; ?>
|
168
|
+
|
169
|
+
|
170
|
+
|
171
|
+
<div class="blogbox">
|
172
|
+
|
173
|
+
<p><span class="kdate">
|
174
|
+
|
175
|
+
<?php if ( get_the_date() != get_the_modified_date() ) : //更新がある場合 ?>
|
176
|
+
|
177
|
+
投稿日:<?php echo esc_html( get_the_date() ); ?>
|
178
|
+
|
179
|
+
更新日:<time class="updated" datetime="<?php echo esc_attr( get_the_modified_date( DATE_ISO8601 ) ); ?>"><?php echo esc_html( get_the_modified_date() ); ?></time>
|
180
|
+
|
181
|
+
<?php else: //更新がない場合 ?>
|
182
|
+
|
183
|
+
投稿日:<time class="updated" datetime="<?php echo esc_attr( get_the_date( DATE_ISO8601 ) ); ?>"><?php echo esc_html( get_the_date() ); ?></time>
|
184
|
+
|
185
|
+
<?php endif; ?>
|
186
|
+
|
187
|
+
</span></p>
|
188
|
+
|
189
|
+
</div>
|
190
|
+
|
191
|
+
|
192
|
+
|
193
|
+
<p>執筆者:<?php the_author_posts_link(); ?></p>
|
194
|
+
|
195
|
+
|
196
|
+
|
197
|
+
<?php endwhile; else: ?>
|
198
|
+
|
199
|
+
<p>記事がありません</p>
|
200
|
+
|
201
|
+
<?php endif; ?>
|
202
|
+
|
203
|
+
<!--ループ終了 -->
|
204
|
+
|
205
|
+
|
206
|
+
|
207
|
+
</article>
|
208
|
+
|
209
|
+
|
210
|
+
|
211
|
+
<?php if ( comments_open() || get_comments_number() ) {
|
212
|
+
|
213
|
+
comments_template(); //コメント
|
214
|
+
|
215
|
+
} ?>
|
216
|
+
|
217
|
+
|
218
|
+
|
219
|
+
<?php get_template_part( 'newpost-page' ); //最近のエントリ ?>
|
220
|
+
|
221
|
+
|
222
|
+
|
223
|
+
</div>
|
224
|
+
|
225
|
+
<!--/post-->
|
226
|
+
|
227
|
+
|
228
|
+
|
229
|
+
</div><!-- /st-main -->
|
230
|
+
|
231
|
+
</div>
|
232
|
+
|
233
|
+
<!-- /#contentInner -->
|
234
|
+
|
235
|
+
<?php get_sidebar(); ?>
|
70
236
|
|
71
237
|
</div>
|
72
238
|
|
73
|
-
<?php if( !is_front_page() ): ?>
|
74
|
-
|
75
|
-
<?php if( !is_front_page() ): ?>
|
76
|
-
|
77
|
-
<!--ぱんくず -->
|
78
|
-
|
79
|
-
<section id="breadcrumb">
|
80
|
-
|
81
|
-
<ol itemscope itemtype="http://schema.org/BreadcrumbList">
|
82
|
-
|
83
|
-
<li itemprop="itemListElement" itemscope
|
84
|
-
|
85
|
-
itemtype="http://schema.org/ListItem"><a href="<?php echo home_url(); ?>" itemprop="item"><span itemprop="name">HOME</span></a> > <meta itemprop="position" content="1" /></li>
|
86
|
-
|
87
|
-
<?php
|
88
|
-
|
89
|
-
$i = 2;
|
90
|
-
|
91
|
-
foreach ( array_reverse( get_post_ancestors( $post->ID ) ) as $parid ) { ?>
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
<li itemprop="itemListElement" itemscope
|
96
|
-
|
97
|
-
itemtype="http://schema.org/ListItem"><a href="<?php echo get_page_link( $parid ); ?>" title="<?php echo get_the_title(); ?>" itemprop="item"> <span itemprop="name"><?php echo get_page( $parid )->post_title; ?></span></a> > <meta itemprop="position" content="<?php echo $i; ?>" /></li>
|
98
|
-
|
99
|
-
<?php $i++; } ?>
|
100
|
-
|
101
|
-
</ol>
|
102
|
-
|
103
|
-
</section>
|
104
|
-
|
105
|
-
<!--/ ぱんくず -->
|
106
|
-
|
107
|
-
<?php endif; ?>
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
<div id="st-page" <?php post_class('post'); ?>>
|
112
|
-
|
113
|
-
<article>
|
114
|
-
|
115
|
-
<!--ループ開始 -->
|
116
|
-
|
117
|
-
<?php if (have_posts()) : while (have_posts()) :
|
118
|
-
|
119
|
-
the_post(); ?>
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
<?php if(!is_front_page()){ ?>
|
124
|
-
|
125
|
-
<h1 class="entry-title"><?php the_title(); //タイトル ?></h1>
|
126
|
-
|
127
|
-
<?php } ?>
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
<div class="mainbox">
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
<div class="entry-content">
|
136
|
-
|
137
|
-
<?php the_content(); //本文 ?>
|
138
|
-
|
139
|
-
</div>
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
<?php //ページ改
|
144
|
-
|
145
|
-
$defaults = array(
|
146
|
-
|
147
|
-
'before' => '<p class="tuzukicenter"><span class="tuzuki">' . __( '', 'default' ),
|
148
|
-
|
149
|
-
'after' => '</span></p>',
|
150
|
-
|
151
|
-
'link_before' => '> ',
|
152
|
-
|
153
|
-
'link_after' => ' ',
|
154
|
-
|
155
|
-
'next_or_number' => 'next',
|
156
|
-
|
157
|
-
'separator' => ' ',
|
158
|
-
|
159
|
-
'nextpagelink' => __( '続きを読む', 'default' ),
|
160
|
-
|
161
|
-
'previouspagelink' => __( '前のページへ', 'default' ),
|
162
|
-
|
163
|
-
'pagelink' => '%',
|
164
|
-
|
165
|
-
'echo' => 1
|
166
|
-
|
167
|
-
);
|
168
|
-
|
169
|
-
wp_link_pages( $defaults );
|
170
|
-
|
171
|
-
?>
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
</div>
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
<?php if( is_front_page() ):
|
180
|
-
|
181
|
-
get_template_part( 'sns-top' ); //トップ用ソーシャルボタン読み込み
|
182
|
-
|
183
|
-
else:
|
184
|
-
|
185
|
-
get_template_part( 'sns' ); //ページ用ソーシャルボタン読み込み
|
186
|
-
|
187
|
-
endif; ?>
|
188
|
-
|
189
|
-
|
190
|
-
|
191
|
-
<div class="blogbox">
|
192
|
-
|
193
|
-
<p><span class="kdate">
|
194
|
-
|
195
|
-
<?php if ( get_the_date() != get_the_modified_date() ) : //更新がある場合 ?>
|
196
|
-
|
197
|
-
投稿日:<?php echo esc_html( get_the_date() ); ?>
|
198
|
-
|
199
|
-
更新日:<time class="updated" datetime="<?php echo esc_attr( get_the_modified_date( DATE_ISO8601 ) ); ?>"><?php echo esc_html( get_the_modified_date() ); ?></time>
|
200
|
-
|
201
|
-
<?php else: //更新がない場合 ?>
|
202
|
-
|
203
|
-
投稿日:<time class="updated" datetime="<?php echo esc_attr( get_the_date( DATE_ISO8601 ) ); ?>"><?php echo esc_html( get_the_date() ); ?></time>
|
204
|
-
|
205
|
-
<?php endif; ?>
|
206
|
-
|
207
|
-
</span></p>
|
208
|
-
|
209
|
-
</div>
|
210
|
-
|
211
|
-
|
212
|
-
|
213
|
-
<p>執筆者:<?php the_author_posts_link(); ?></p>
|
214
|
-
|
215
|
-
|
216
|
-
|
217
|
-
<?php endwhile; else: ?>
|
218
|
-
|
219
|
-
<p>記事がありません</p>
|
220
|
-
|
221
|
-
<?php endif; ?>
|
222
|
-
|
223
|
-
<!--ループ終了 -->
|
224
|
-
|
225
|
-
|
226
|
-
|
227
|
-
</article>
|
228
|
-
|
229
|
-
|
230
|
-
|
231
|
-
<?php if ( comments_open() || get_comments_number() ) {
|
232
|
-
|
233
|
-
comments_template(); //コメント
|
234
|
-
|
235
|
-
} ?>
|
236
|
-
|
237
|
-
|
238
|
-
|
239
|
-
<?php get_template_part( 'newpost-page' ); //最近のエントリ ?>
|
240
|
-
|
241
|
-
|
242
|
-
|
243
|
-
</div>
|
244
|
-
|
245
|
-
<!--/post-->
|
246
|
-
|
247
|
-
|
248
|
-
|
249
|
-
</div><!-- /st-main -->
|
250
|
-
|
251
|
-
</div>
|
252
|
-
|
253
|
-
<!-- /#contentInner -->
|
254
|
-
|
255
|
-
<?php get_sidebar(); ?>
|
256
|
-
|
257
|
-
</div>
|
258
|
-
|
259
239
|
<!--/#content -->
|
260
240
|
|
261
241
|
<?php get_footer(); ?>
|
1
page\.php追記しました
test
CHANGED
File without changes
|
test
CHANGED
@@ -29,3 +29,235 @@
|
|
29
29
|
|
30
30
|
|
31
31
|
###補足情報(言語/FW/ツール等のバージョンなど)
|
32
|
+
|
33
|
+
```<?php get_header(); ?>
|
34
|
+
|
35
|
+
|
36
|
+
|
37
|
+
<div id="content" class="clearfix">
|
38
|
+
|
39
|
+
<div id="contentInner">
|
40
|
+
|
41
|
+
<div class="st-main">
|
42
|
+
|
43
|
+
<div class=”st-main”>
|
44
|
+
|
45
|
+
<div>
|
46
|
+
|
47
|
+
スポンサードリンク
|
48
|
+
|
49
|
+
</div>
|
50
|
+
|
51
|
+
<div>
|
52
|
+
|
53
|
+
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
|
54
|
+
|
55
|
+
<!-- バナー用テキスト -->
|
56
|
+
|
57
|
+
<ins class="adsbygoogle"
|
58
|
+
|
59
|
+
style="display:inline-block;width:728px;height:90px"
|
60
|
+
|
61
|
+
data-ad-client="ca-pub-3177082317388295"
|
62
|
+
|
63
|
+
data-ad-slot="6718938763"></ins>
|
64
|
+
|
65
|
+
<script>
|
66
|
+
|
67
|
+
(adsbygoogle = window.adsbygoogle || []).push({});
|
68
|
+
|
69
|
+
</script>
|
70
|
+
|
71
|
+
</div>
|
72
|
+
|
73
|
+
<?php if( !is_front_page() ): ?>
|
74
|
+
|
75
|
+
<?php if( !is_front_page() ): ?>
|
76
|
+
|
77
|
+
<!--ぱんくず -->
|
78
|
+
|
79
|
+
<section id="breadcrumb">
|
80
|
+
|
81
|
+
<ol itemscope itemtype="http://schema.org/BreadcrumbList">
|
82
|
+
|
83
|
+
<li itemprop="itemListElement" itemscope
|
84
|
+
|
85
|
+
itemtype="http://schema.org/ListItem"><a href="<?php echo home_url(); ?>" itemprop="item"><span itemprop="name">HOME</span></a> > <meta itemprop="position" content="1" /></li>
|
86
|
+
|
87
|
+
<?php
|
88
|
+
|
89
|
+
$i = 2;
|
90
|
+
|
91
|
+
foreach ( array_reverse( get_post_ancestors( $post->ID ) ) as $parid ) { ?>
|
92
|
+
|
93
|
+
|
94
|
+
|
95
|
+
<li itemprop="itemListElement" itemscope
|
96
|
+
|
97
|
+
itemtype="http://schema.org/ListItem"><a href="<?php echo get_page_link( $parid ); ?>" title="<?php echo get_the_title(); ?>" itemprop="item"> <span itemprop="name"><?php echo get_page( $parid )->post_title; ?></span></a> > <meta itemprop="position" content="<?php echo $i; ?>" /></li>
|
98
|
+
|
99
|
+
<?php $i++; } ?>
|
100
|
+
|
101
|
+
</ol>
|
102
|
+
|
103
|
+
</section>
|
104
|
+
|
105
|
+
<!--/ ぱんくず -->
|
106
|
+
|
107
|
+
<?php endif; ?>
|
108
|
+
|
109
|
+
|
110
|
+
|
111
|
+
<div id="st-page" <?php post_class('post'); ?>>
|
112
|
+
|
113
|
+
<article>
|
114
|
+
|
115
|
+
<!--ループ開始 -->
|
116
|
+
|
117
|
+
<?php if (have_posts()) : while (have_posts()) :
|
118
|
+
|
119
|
+
the_post(); ?>
|
120
|
+
|
121
|
+
|
122
|
+
|
123
|
+
<?php if(!is_front_page()){ ?>
|
124
|
+
|
125
|
+
<h1 class="entry-title"><?php the_title(); //タイトル ?></h1>
|
126
|
+
|
127
|
+
<?php } ?>
|
128
|
+
|
129
|
+
|
130
|
+
|
131
|
+
<div class="mainbox">
|
132
|
+
|
133
|
+
|
134
|
+
|
135
|
+
<div class="entry-content">
|
136
|
+
|
137
|
+
<?php the_content(); //本文 ?>
|
138
|
+
|
139
|
+
</div>
|
140
|
+
|
141
|
+
|
142
|
+
|
143
|
+
<?php //ページ改
|
144
|
+
|
145
|
+
$defaults = array(
|
146
|
+
|
147
|
+
'before' => '<p class="tuzukicenter"><span class="tuzuki">' . __( '', 'default' ),
|
148
|
+
|
149
|
+
'after' => '</span></p>',
|
150
|
+
|
151
|
+
'link_before' => '> ',
|
152
|
+
|
153
|
+
'link_after' => ' ',
|
154
|
+
|
155
|
+
'next_or_number' => 'next',
|
156
|
+
|
157
|
+
'separator' => ' ',
|
158
|
+
|
159
|
+
'nextpagelink' => __( '続きを読む', 'default' ),
|
160
|
+
|
161
|
+
'previouspagelink' => __( '前のページへ', 'default' ),
|
162
|
+
|
163
|
+
'pagelink' => '%',
|
164
|
+
|
165
|
+
'echo' => 1
|
166
|
+
|
167
|
+
);
|
168
|
+
|
169
|
+
wp_link_pages( $defaults );
|
170
|
+
|
171
|
+
?>
|
172
|
+
|
173
|
+
|
174
|
+
|
175
|
+
</div>
|
176
|
+
|
177
|
+
|
178
|
+
|
179
|
+
<?php if( is_front_page() ):
|
180
|
+
|
181
|
+
get_template_part( 'sns-top' ); //トップ用ソーシャルボタン読み込み
|
182
|
+
|
183
|
+
else:
|
184
|
+
|
185
|
+
get_template_part( 'sns' ); //ページ用ソーシャルボタン読み込み
|
186
|
+
|
187
|
+
endif; ?>
|
188
|
+
|
189
|
+
|
190
|
+
|
191
|
+
<div class="blogbox">
|
192
|
+
|
193
|
+
<p><span class="kdate">
|
194
|
+
|
195
|
+
<?php if ( get_the_date() != get_the_modified_date() ) : //更新がある場合 ?>
|
196
|
+
|
197
|
+
投稿日:<?php echo esc_html( get_the_date() ); ?>
|
198
|
+
|
199
|
+
更新日:<time class="updated" datetime="<?php echo esc_attr( get_the_modified_date( DATE_ISO8601 ) ); ?>"><?php echo esc_html( get_the_modified_date() ); ?></time>
|
200
|
+
|
201
|
+
<?php else: //更新がない場合 ?>
|
202
|
+
|
203
|
+
投稿日:<time class="updated" datetime="<?php echo esc_attr( get_the_date( DATE_ISO8601 ) ); ?>"><?php echo esc_html( get_the_date() ); ?></time>
|
204
|
+
|
205
|
+
<?php endif; ?>
|
206
|
+
|
207
|
+
</span></p>
|
208
|
+
|
209
|
+
</div>
|
210
|
+
|
211
|
+
|
212
|
+
|
213
|
+
<p>執筆者:<?php the_author_posts_link(); ?></p>
|
214
|
+
|
215
|
+
|
216
|
+
|
217
|
+
<?php endwhile; else: ?>
|
218
|
+
|
219
|
+
<p>記事がありません</p>
|
220
|
+
|
221
|
+
<?php endif; ?>
|
222
|
+
|
223
|
+
<!--ループ終了 -->
|
224
|
+
|
225
|
+
|
226
|
+
|
227
|
+
</article>
|
228
|
+
|
229
|
+
|
230
|
+
|
231
|
+
<?php if ( comments_open() || get_comments_number() ) {
|
232
|
+
|
233
|
+
comments_template(); //コメント
|
234
|
+
|
235
|
+
} ?>
|
236
|
+
|
237
|
+
|
238
|
+
|
239
|
+
<?php get_template_part( 'newpost-page' ); //最近のエントリ ?>
|
240
|
+
|
241
|
+
|
242
|
+
|
243
|
+
</div>
|
244
|
+
|
245
|
+
<!--/post-->
|
246
|
+
|
247
|
+
|
248
|
+
|
249
|
+
</div><!-- /st-main -->
|
250
|
+
|
251
|
+
</div>
|
252
|
+
|
253
|
+
<!-- /#contentInner -->
|
254
|
+
|
255
|
+
<?php get_sidebar(); ?>
|
256
|
+
|
257
|
+
</div>
|
258
|
+
|
259
|
+
<!--/#content -->
|
260
|
+
|
261
|
+
<?php get_footer(); ?>
|
262
|
+
|
263
|
+
```
|