- 赤色のリンクは、まだ日本語Codexに存在しないページ・画像です。英語版と併せてご覧ください。(詳細)
「関数リファレンス/add custom background」の版間の差分
提供: WordPress Codex 日本語版
< 関数リファレンス
細 (テンプレートタグガイド・カテゴリー挿入等/翻訳者募集中) |
細 (→更新履歴) |
||
(同じ利用者による、間の6版が非表示) | |||
1行目: | 1行目: | ||
− | {{ | + | {{Deprecated|new_function()=add_theme_support}} |
− | + | ||
− | |||
− | + | == 説明 == | |
− | + | 背景画像表示のためのコールバックを追加します。 | |
− | + | The parameter <tt>$header_callback</tt> callback will be required to display the content for the '<tt>wp_head</tt>' action. The parameter <tt>$admin_header_callback</tt> callback will be added to Custom_Background class and that will be added to the '<tt>admin_menu</tt>' action. | |
− | + | == 使い方 == | |
− | == | + | <?php add_custom_background( $header_callback, $admin_header_callback, $admin_image_div_callback ) ?> |
+ | |||
+ | == パラメータ == | ||
{{Parameter|$header_callback|callback|Call on '<tt>wp_head</tt>' action.|optional|''}} | {{Parameter|$header_callback|callback|Call on '<tt>wp_head</tt>' action.|optional|''}} | ||
18行目: | 18行目: | ||
{{Parameter|$admin_image_div_callback|callback|Output a custom background image div on the custom background administration screen. Optional.|optional|''}} | {{Parameter|$admin_image_div_callback|callback|Output a custom background image div on the custom background administration screen. Optional.|optional|''}} | ||
− | == | + | == 戻り値 == |
− | ; (void) : | + | ; (void) : この関数は値を返しません。 |
− | == | + | == 用例 == |
<!-- Need creative examples. Feel free to link to external examples. --> | <!-- Need creative examples. Feel free to link to external examples. --> | ||
− | == | + | == 注 == |
* Uses: Custom_Background Sets up for <tt>$admin_header_callback</tt> for administration panel display. | * Uses: Custom_Background Sets up for <tt>$admin_header_callback</tt> for administration panel display. | ||
− | == | + | == 更新履歴 == |
− | + | 導入:[[Version 3.0|3.0.0]] | |
+ | 非推奨:[[Version 3.4|3.4.0]] | ||
− | == | + | == ソースファイル == |
− | <tt>add_custom_background()</tt> | + | <tt>add_custom_background()</tt> は {{Trac|wp-includes/theme.php}}にあります。 |
− | == | + | == 関連資料 == |
* [[Theme Review#Functionality|Theme Review - Guidelines]] (recommended) | * [[Theme Review#Functionality|Theme Review - Guidelines]] (recommended) | ||
− | + | ||
{{Tag Footer}} | {{Tag Footer}} | ||
48行目: | 49行目: | ||
{{原文|Function Reference/add_custom_background|92983}}<!-- 12:36, 15 September 2010 bono 版 --> | {{原文|Function Reference/add_custom_background|92983}}<!-- 12:36, 15 September 2010 bono 版 --> | ||
− | + | ||
[[Category:関数]] | [[Category:関数]] | ||
− | [[Category: | + | [[Category:非推奨]] |
[[Category:wp3.0]] | [[Category:wp3.0]] | ||
[[en:Function Reference/add_custom_background]] | [[en:Function Reference/add_custom_background]] |
2015年5月12日 (火) 12:52時点における最新版
この関数は 非推奨となりました。これは新しい関数に置き換えられた、またはサポート外になった、あるいは将来バージョンにて削除されるためです。この関数を用いる全てのコードは、置き換えとなる関数が存在する場合、書き換えられる必要があります。
wp-includes/deprecated.php
もご参照ください。
これらの関数から適切なものを代わりに用いてください。
説明
背景画像表示のためのコールバックを追加します。
The parameter $header_callback callback will be required to display the content for the 'wp_head' action. The parameter $admin_header_callback callback will be added to Custom_Background class and that will be added to the 'admin_menu' action.
使い方
<?php add_custom_background( $header_callback, $admin_header_callback, $admin_image_div_callback ) ?>
パラメータ
- $header_callback
- (callback) (optional) Call on 'wp_head' action.
- 初期値: ''
- $admin_header_callback
- (callback) (optional) Call on custom background administration screen.
- 初期値: ''
- $admin_image_div_callback
- (callback) (optional) Output a custom background image div on the custom background administration screen. Optional.
- 初期値: ''
戻り値
- (void)
- この関数は値を返しません。
用例
注
- Uses: Custom_Background Sets up for $admin_header_callback for administration panel display.
更新履歴
ソースファイル
add_custom_background() は wp-includes/theme.php
にあります。
関連資料
- Theme Review - Guidelines (recommended)
関数リファレンス、テンプレートタグ目次もご覧ください。
最新英語版: WordPress Codex » Function Reference/add_custom_background (最新版との差分)