ご質問されて頂きます。
WORDPRESS初心者です。
テーマは「Luxeritas」です。
Luxeritasはこちらからダウンロードしました。
https://thk.kanzae.net/wp/dl/
「野党合同ヒアリング図書館」というサイトを構築しています。
https://yasaidemo.com/goudou-hearing/
※こちらの質問の続きです。
https://teratail.com/questions/169659
●質問したいこと
トップページのコンテンツ領域(イメージ図①の青い範囲)をカスタマイズしたい。
→デフォルトでは件名やアイキャッチが表示になっているのを
カスタムフィールドを表示させたい。(イメージ図②)
(なお、カスタムフィールドの項目は作成済)
single.phpに書き込んだところ
それぞれの記事のページは修正できました
https://yasaidemo.com/goudou-hearing/2019/01/04/%e8%b2%a1%e5%8b%99%e7%9c%81%e3%80%8c%e6%a3%ae%e5%8f%8b%e6%96%87%e6%9b%b8%e3%80%8d%e6%94%b9%e3%81%96%e3%82%93%e5%95%8f%e9%a1%8c-3/
ただ、トップページのコンテンツ領域が変わりません。
https://yasaidemo.com/goudou-hearing/
**
トップページのコンテンツ領域に表示させるためのコードを
どのファイルの、どの意味に書き込めば**
カスタムフィールドのデータを表示させることができるのか
教えていただければ幸いです。
<table class="m01"> <tr> <th class="t_top">カテゴリ</th> </tr> <tr> <td class="m01"><?php the_field('THEMA'); ?></td> </tr> <tr> <th class="t_top">開催日</th> </tr> <tr> <td class="m01"><?php the_field('kaisai_date'); ?></td> </tr> <tr> <th class="t_top">URL</th> </tr> <tr> <td class="m01"><a href="<?php the_field('DOUGA_URL'); ?>" target="_blank"><?php the_field('DOUGA_URL'); ?></a></td> </tr> <tr> <th class="t_top">出席議員(確認できる人のみ)</th> </tr> <tr> <td class="m01"><?php the_field('SYUSEKISYA'); ?></td> </tr> <tr> <th class="t_top">概要</th> </tr> <tr> <td class="m01"><?php the_field('GAIYO'); ?></td> </tr> <?php if( get_field('gazou') ) { ?> <tr> <th class="t_top">関連記事</th> </tr> <tr> <td class="m01"><a href="<?php the_field('gazou'); ?>"> <img src="<?php the_field('gazou'); ?>" width="550" /></a></td> </tr> <?php } ?> </table>
回答1件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。
2019/01/20 02:12