• 赤色のリンクは、まだ日本語Codexに存在しないページ・画像です。英語版と併せてご覧ください。(詳細

このWikiはいつでも誰でも編集できます

「テンプレートタグ/get bookmarks」の版間の差分

提供: WordPress Codex 日本語版
移動先: 案内検索
(en:Template Tags/get_bookmarks 18:20, December 6, 2007 Otto42 版を翻訳用にコピー)
 
(Wiki 書式・リンク調整、未翻訳)
1行目: 1行目:
== Description ==
+
{{NeedTrans}}
This function will be found in WordPress v2.1, it is NOT supported by WordPress v2.0. get_bookmarks() returns an array of bookmarks found in the [[Administration_Panels|Administration]] > [[Administration_Panels#Manage_Blogroll|Blogroll]] > [[Manage_Blogroll_SubPanel|Manage Blogroll]] panel.  This [[Template_Tags|Template Tag]] allows the user to retrieve the bookmark information directly.
+
<div id="Description">
 +
== 説明 ==
 +
</div>
 +
This function will be found in [[Version 2.1|WordPress v2.1]], it is NOT supported by WordPress v2.0. get_bookmarks() returns an array of bookmarks found in the [[管理パネル|Administration]] > [[管理パネル#Manage - Change your content|Manage]] > [[Manage Links SubPanel|Manage Links]]/[[:en:Manage Links SubPanel|en]] panel.  This [[テンプレートタグ|Template Tag]] allows the user to retrieve the bookmark information directly.
  
== Usage ==
+
<div id="Usage">
%%% <?php get_bookmarks('arguments'); ?> %%%
+
== 使い方 ==
 +
</div>
 +
<?php get_bookmarks('引数'); ?>  
  
== Examples ==
+
<div id="Examples">
 +
== 用例 ==
 +
</div>
  
===Default Usage===
+
<div id="Default_Usage">
 +
=== 初期設定での使用 ===
 +
</div>
 
<pre>
 
<pre>
 
'orderby' => 'name',  
 
'orderby' => 'name',  
25行目: 34行目:
 
* The link_updated_f field (the update time in the form of a timestamp) is not returned.
 
* The link_updated_f field (the update time in the form of a timestamp) is not returned.
  
== Parameters ==
+
<div id="Parameters">
; orderby : (''string'') Value to sort bookmarks on. Defaults to <tt>'name'</tt> unless you pass the value of <tt>&#39;&#39;</tt> (empty), in which case it sets to <tt>'id'</tt>. Valid options:
+
== パラメータ ==
:* <tt>'id'</tt>
+
</div>
:* <tt>'url'</tt>
+
; orderby  
:* <tt>'name'</tt>
+
: (''string'') Value to sort bookmarks on. Defaults to <code>'name'</code> unless you pass the value of <code>&#39;&#39;</code> (empty), in which case it sets to <code>'id'</code>. Valid options:
:* <tt>'target'</tt>
+
:* <code>'id'</code>
:* <tt>'description'</tt>
+
:* <code>'url'</code>
:* <tt>'owner'</tt> - User who added bookmark through bookmarks Manager.
+
:* <code>'name'</code>
:* <tt>'rating'</tt>
+
:* <code>'target'</code>
:* <tt>'updated'</tt>
+
:* <code>'description'</code>
:* <tt>'rel'</tt> - bookmark relationship (XFN).
+
:* <code>'owner'</code> - User who added bookmark through bookmarks Manager.
:* <tt>'notes'</tt>
+
:* <code>'rating'</code>
:* <tt>'rss'</tt>
+
:* <code>'updated'</code>
:* <tt>'length'</tt> - The length of the bookmark name, shortest to longest.   
+
:* <code>'rel'</code> - bookmark relationship (XFN).
:* <tt>'rand'</tt> - Display bookmarks in random order.   
+
:* <code>'notes'</code>
; order : (''string'') Sort order, ascending or descending for the orderby parameter. Valid values:
+
:* <code>'rss'</code>
:* <tt>ASC</tt> (Default)
+
:* <code>'length'</code> - The length of the bookmark name, shortest to longest.   
:* <tt>DESC</tt>
+
:* <code>'rand'</code> - Display bookmarks in random order.   
; limit : (''integer'') Maximum number of bookmarks to display. Defaults to <tt>-1</tt> (all bookmarks).
+
; order  
; category : (''string'') Comma separated list of bookmark category ID's.
+
: (''string'') Sort order, ascending or descending for the orderby parameter. Valid values:
; category_name : (''string'') Category name of a catgeory of bookmarks to retrieve. Overrides category parameter.
+
:* <code>ASC</code> (Default)
; hide_invisible : (''boolean'') TRUE causes only bookmarks with link_visible set to 'Y' to be retrieved.
+
:* <code>DESC</code>
:* <tt>1</tt> (True - default)
+
; limit  
:* <tt>0</tt> (False)
+
: (''integer'') Maximum number of bookmarks to display. Defaults to <code>-1</code> (all bookmarks).
; show_updated : (''boolean'') TRUE causes an extra column called "link_category_f" to be inserted into the results, which contains the same value as "link_updated", but in a unix timestamp format. Handy for using PHP date functions on this data.
+
; category  
:* <tt>1</tt> (True)
+
: (''string'') Comma separated list of bookmark category ID's.
:* <tt>0</tt> (False - default)
+
; category_name  
; include : (''string'') Comma separated list of numeric bookmark IDs to include in the output.  For example, 'include=1,3,6' means to return or echo bookmark IDs 1, 3, and 6.  If the include string is used, the ''category'', ''category_name'', and ''exclude'' parameters are ignored.  Defaults to <tt>''</tt> (all Bookmarks).
+
: (''string'') Category name of a catgeory of bookmarks to retrieve. Overrides category parameter.
; exclude : (''string'') Comma separated list of numeric bookmark IDs to exclude.  For example, 'exclude=4,12' means that bookmark IDs 4 and 12 will NOT be returned or echoed.  Defaults to <tt>''</tt> (exclude nothing).
+
; hide_invisible  
 +
: (''boolean'') TRUE causes only bookmarks with link_visible set to 'Y' to be retrieved.
 +
:* <code>1</code> (True - default)
 +
:* <code>0</code> (False)
 +
; show_updated  
 +
: (''boolean'') TRUE causes an extra column called "link_category_f" to be inserted into the results, which contains the same value as "link_updated", but in a unix timestamp format. Handy for using PHP date functions on this data.
 +
:* <code>1</code> (True)
 +
:* <code>0</code> (False - default)
 +
; include  
 +
: (''string'') Comma separated list of numeric bookmark IDs to include in the output.  For example, 'include=1,3,6' means to return or echo bookmark IDs 1, 3, and 6.  If the include string is used, the ''category'', ''category_name'', and ''exclude'' parameters are ignored.  Defaults to <code>''</code> (all Bookmarks).
 +
; exclude  
 +
: (''string'') Comma separated list of numeric bookmark IDs to exclude.  For example, 'exclude=4,12' means that bookmark IDs 4 and 12 will NOT be returned or echoed.  Defaults to <code>''</code> (exclude nothing).
  
== Related ==
+
== 変更履歴 ==
 +
* [[Version 2.1|2.1]] : 新規テンプレートタグ
 +
 
 +
<div id="Related">
 +
== 関連 ==
 +
</div>
  
 
{{Tag bookmark Manager Tags}}
 
{{Tag bookmark Manager Tags}}
61行目: 86行目:
 
{{PHP Function Tag Footer}}
 
{{PHP Function Tag Footer}}
  
[[Category:New page created]]
+
{{原文|Template Tags/get_bookmarks|51914}}<!-- 18:20, December 6, 2007 Otto42 版 -->
 +
 
 +
{{DEFAULTSORT:get_bookmarks}}
 +
 
 +
[[en:Template Tags/get_bookmarks]]

2008年8月9日 (土) 23:55時点における版

このページ「テンプレートタグ/get bookmarks」は未翻訳です。和訳や日本語情報を加筆してくださる協力者を求めています

This function will be found in WordPress v2.1, it is NOT supported by WordPress v2.0. get_bookmarks() returns an array of bookmarks found in the Administration > Manage > Manage Links/en panel. This Template Tag allows the user to retrieve the bookmark information directly.

使い方

<?php get_bookmarks('引数'); ?> 

用例

初期設定での使用

'orderby' => 'name', 
'order' => 'ASC',
'limit' => -1, 
'category' => '',
'category_name' => '', 
'hide_invisible' => 1,
'show_updated' => 0, 
'include' => '',
'exclude' => ''

By default, the usage gets:

  • All bookmarks ordered by name, ascending
  • Bookmarks marked as hidden are not returned.
  • The link_updated_f field (the update time in the form of a timestamp) is not returned.

パラメータ

orderby
(string) Value to sort bookmarks on. Defaults to 'name' unless you pass the value of '' (empty), in which case it sets to 'id'. Valid options:
  • 'id'
  • 'url'
  • 'name'
  • 'target'
  • 'description'
  • 'owner' - User who added bookmark through bookmarks Manager.
  • 'rating'
  • 'updated'
  • 'rel' - bookmark relationship (XFN).
  • 'notes'
  • 'rss'
  • 'length' - The length of the bookmark name, shortest to longest.
  • 'rand' - Display bookmarks in random order.
order
(string) Sort order, ascending or descending for the orderby parameter. Valid values:
  • ASC (Default)
  • DESC
limit
(integer) Maximum number of bookmarks to display. Defaults to -1 (all bookmarks).
category
(string) Comma separated list of bookmark category ID's.
category_name
(string) Category name of a catgeory of bookmarks to retrieve. Overrides category parameter.
hide_invisible
(boolean) TRUE causes only bookmarks with link_visible set to 'Y' to be retrieved.
  • 1 (True - default)
  • 0 (False)
show_updated
(boolean) TRUE causes an extra column called "link_category_f" to be inserted into the results, which contains the same value as "link_updated", but in a unix timestamp format. Handy for using PHP date functions on this data.
  • 1 (True)
  • 0 (False - default)
include
(string) Comma separated list of numeric bookmark IDs to include in the output. For example, 'include=1,3,6' means to return or echo bookmark IDs 1, 3, and 6. If the include string is used, the category, category_name, and exclude parameters are ignored. Defaults to (all Bookmarks).
exclude
(string) Comma separated list of numeric bookmark IDs to exclude. For example, 'exclude=4,12' means that bookmark IDs 4 and 12 will NOT be returned or echoed. Defaults to (exclude nothing).

変更履歴

  • 2.1 : 新規テンプレートタグ


ブックマークタグ: wp_list_bookmarks, get_bookmarks, get_bookmark get_bookmark_field


テンプレートタグへの PHP 関数型パラメータの渡し方関数リファレンステンプレートタグ目次もご覧ください。


最新英語版: WordPress Codex » Template Tags/get_bookmarks最新版との差分