Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

テーマ内に設置したBlog/default/posts.php が $this->BcBaser->blogPostsで読み込まれない #2303

Closed
kaburk opened this issue Jun 7, 2023 · 4 comments
Labels
Reviewed レビュー済
Milestone

Comments

@kaburk
Copy link
Collaborator

kaburk commented Jun 7, 2023

概要

テーマ(初期状態だと BcThemeSample )内 plugins/BcThemeSample/templates/plugin/BcBlog/Blog/default 内に
ブログのテンプレート各種ファイルを設置しても $this->BcBaser->blogPosts で posts.phpが正しく読み込まれず、
bc-frontの posts.php が優先されて読み込まれてしまっているようです。

plugins/bc-front/templates/plugin/BcBlog/Blog/default/posts.php
plugins/BcThemeSample/templates/plugin/BcBlog/Blog/default/posts.php

baserCMS version : 5.0.1

備考

index.php、archives.php、single.php については テーマ内に設置したものが優先されるようです
(正しい動作)

@ryuring ryuring added the Bug バグ label Jun 8, 2023
@ryuring
Copy link
Collaborator

ryuring commented Jun 8, 2023

ちょっと見てみますね @kaburk

@ryuring
Copy link
Collaborator

ryuring commented Jun 8, 2023

@kaburk こちらの件、確認しました。
baserCMS4の時も同様の仕様だったのですが、element ディレクトリが必要となるようです。

このパスに配置する場合は

plugins/BcThemeSample/templates/plugin/BcBlog/Blog/default/posts.php

次の element ディレクトリが必要になります。

plugins/BcThemeSample/templates/plugin/BcBlog/element/

次のパスに配置する場合は

plugins/BcThemeSample/templates/Blog/default/posts.php

次の element ディレクトリが必要になります。

plugins/BcThemeSample/templates/element/

@ryuring
Copy link
Collaborator

ryuring commented Jun 8, 2023

@ryuring ryuring added Reviewed レビュー済 and removed Bug バグ labels Jun 8, 2023
@ryuring
Copy link
Collaborator

ryuring commented Jun 8, 2023

あと、BcThemeSampleには、element を配置しておきました。
25aaf70

@ryuring ryuring closed this as completed Jun 9, 2023
@ryuring ryuring added this to the 5.0.2 milestone Jun 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Reviewed レビュー済
Projects
None yet
Development

No branches or pull requests

2 participants