Warning: Attempt to read property "post_content" on null in /home/xs204598/houousei.com/public_html/earlyado-akira/wp-content/plugins/custom-css-js/custom-css-js.php on line 206

Warning: Attempt to read property "post_content" on null in /home/xs204598/houousei.com/public_html/earlyado-akira/wp-content/plugins/custom-css-js/custom-css-js.php on line 206
背景動画切り替え

child-themes

今回は子テーマがないテーマに子テーマを追加してみるということをやってみました。
親テーマに選定したのはTwenty Twenty-Five。やり方はググって、調べました。手順を簡単にまとめると、①PCのローカルに子テーマ用のフォルダを作成②functions.phpとstyle.cssを準備②-1 functions.phpの中身はお決まり(らしい)②-2 style.cssの中身は親テーマによって変えるところがある③準備できたら、フォルダごとzipで圧縮④WordPressの管理画面で読み込んで有効化
これだけ。

functions.phpの中身


つまづいたのは、style.cssです。
style.cssの中身↓

なにがつまづいたのかというと、親テーマの名前です。twentytwentyfiveはどこから取ってきたのかというと親テーマのフォルダ名。ここがなかなか気づけなかった。一度分かれば大したことないですが。

コメント

タイトルとURLをコピーしました