WordPressユーザーのbaserCMS覚え書き


テーマディレクトリのパスを出力する

WordPress

bloginfo( 'stylesheet_directory' )

テンプレートタグ/bloginfo - WordPress Codex 日本語版

baserCMS(3系)

$this->BcBaser->themeUrl()

メモ

baserCMS3で初めて実装された関数(テンプレートタグ)です。テンプレートファイルに

<?php $this->BcBaser->themeUrl() ?>

と記述すると /theme/{テーマディレクトリ名}/ が出力されます。

ちなみに、WordPressのCodexでは bloginfo( 'stylesheet_directory' ) の代わりに

<?php echo get_stylesheet_directory_uri(); ?>

を使うことが推奨されています。