Title: Custom Query Fields
Author: julian1828
Published: <strong>2011年5月8日</strong>
Last modified: 2011年5月10日

---

プラグインを検索

このプラグインは **WordPress の最新3回のメジャーリリースに対してテストされていま
せん**。もうメンテナンスやサポートがされていないかもしれず、最新バージョンの WordPress
で使用した場合は互換性の問題が発生する可能性があります。

![](https://s.w.org/plugins/geopattern-icon/custom-query-fields.svg)

# Custom Query Fields

 作者: [julian1828](https://profiles.wordpress.org/julian1828/)

[ダウンロード](https://downloads.wordpress.org/plugin/custom-query-fields.zip)

 * [詳細](https://ja.wordpress.org/plugins/custom-query-fields/#description)
 * [レビュー](https://ja.wordpress.org/plugins/custom-query-fields/#reviews)
 *  [インストール](https://ja.wordpress.org/plugins/custom-query-fields/#installation)
 * [開発](https://ja.wordpress.org/plugins/custom-query-fields/#developers)

 [サポート](https://wordpress.org/support/plugin/custom-query-fields/)

## 説明

THIS PLUGIN IS IN HEAVY DEVELOPMENT!

Extend your site’s querying and sorting functionality using custom field values.

The following function registers queryable fields.
 register_custom_queryable_field(
$fieldName, $options);

Simple Example:
 register_custom_queryable_field(‘city’); (The above registers the
custom field ‘city’ to be searchable using query variables) http://www.yoursite.
com/?city=Anahiem (displays posts which have a meta key ‘city’ and a value of ‘Anahiem’)

Advanced Example:
 register_custom_queryable_field(“price”, array(“dataType”=>”numeric”));(
The above registers the custom field “price” to be searchable as a number using 
query variables) http://www.yoursite.com/?price=500 (displays posts which have a
meta key ‘price’ and a exact value of ‘500’) http://www.yoursite.com/?price_min=
200&price_max=800&order_by=price (displays posts, sorted by ‘price’, which have 
a meta key ‘price’ and a value between ‘200’ and ‘800’)

Available Options:

 * dataType
    - text (default)
    - numeric (receive min/max query variables, see above example)
 * order
    - If the user uses the “order_by” query variable then this option determines
      the order. Available options are “ASC” and “DESC”(default)
 * compare
    - Compare method for text types. Defaults to ‘=’. Recommend ‘LIKE’

There is a “order_by” query var made available. This is used by adding `&order_by
=price` to the URL. In this instance, the query would sort based on the “price” 
field only.

Note: This plugin does not alter any queries when in the backend.

## インストール

 1. Upload `custom-query-fields` directory to the `/wp-content/plugins/` directory
 2. Activate the plugin through the ‘Plugins’ menu in WordPress
 3. See Description on how to enable the custom variables.

## FAQ

  When will you have some FAQ’s?

Soon.

## 評価

このプラグインにはレビューがありません。

## 貢献者と開発者

Custom Query Fields はオープンソースソフトウェアです。以下の人々がこのプラグイン
に貢献しています。

貢献者

 *   [ julian1828 ](https://profiles.wordpress.org/julian1828/)

[“Custom Query Fields” をあなたの言語に翻訳しましょう。](https://translate.wordpress.org/projects/wp-plugins/custom-query-fields)

### 開発に興味がありますか ?

[コードを閲覧](https://plugins.trac.wordpress.org/browser/custom-query-fields/)する
か、[SVN リポジトリ](https://plugins.svn.wordpress.org/custom-query-fields/)をチェック
するか、[開発ログ](https://plugins.trac.wordpress.org/log/custom-query-fields/)を
[RSS](https://plugins.trac.wordpress.org/log/custom-query-fields/?limit=100&mode=stop_on_copy&format=rss)
で購読してみてください。

## 変更履歴

#### 0.1.2b

 * Fixed some foreach bugs that threw warnings if no fields were registered.
 * The plugin is now only using one global variable.
 * Added backward compatibility with version 3.0.
 * Improved code efficiency.
 * Added enable and disable functions to allow you to apply custom field query to
   external query’s.

#### 0.1.1b

 * Added the ability to control whether the query altering function is run only 
   once.
 * Added the compare option to the registered fields. This compare is ignored for
   numeric comparisons.

#### 0.1b

 * Initial build.

## メタ

 *  バージョン **0.1.2b**
 *  最終更新日 **15年前**
 *  有効インストール数 **10+**
 *  WordPress バージョン ** 3.0またはそれ以降 **
 *  検証済み最新バージョン: **3.1.4**
 *  言語
 * [English (US)](https://wordpress.org/plugins/custom-query-fields/)
 * タグ
 * [custom fields](https://ja.wordpress.org/plugins/tags/custom-fields/)[meta_query](https://ja.wordpress.org/plugins/tags/meta_query/)
   [query](https://ja.wordpress.org/plugins/tags/query/)
 *  [詳細を表示](https://ja.wordpress.org/plugins/custom-query-fields/advanced/)

## 評価

レビューはまだ送信されていません。

[Your review](https://wordpress.org/support/plugin/custom-query-fields/reviews/#new-post)

[すべてのレビューを見る](https://wordpress.org/support/plugin/custom-query-fields/reviews/)

## 貢献者

 *   [ julian1828 ](https://profiles.wordpress.org/julian1828/)

## サポート

意見や質問がありますか ?

 [サポートフォーラムを表示](https://wordpress.org/support/plugin/custom-query-fields/)

## 寄付

このプラグインが今後も改善できるよう応援しませんか ?

 [ このプラグインに寄付 ](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=9BBXFXSUG2D6U)