Title: Sort Query Posts
Author: Tubal
Published: <strong>2011년 1월 15일</strong>
Last modified: 2012년 9월 4일

---

플러그인 검색

이 플러그인은 **최근 3개의 주요 워드프레스 출시와 시험 되지 않았습니다**. 워드프레스의
좀 더 최근 버전으로 이용할 때 더 이상 관리되지 않고 지원되지 않고 호환성 문제가 
있을 수 있습니다.

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

# Sort Query Posts

 작성자: [Tubal](https://profiles.wordpress.org/tubal/)

[다운로드](https://downloads.wordpress.org/plugin/sort-query-posts.1.1.zip)

 * [세부사항](https://ko.wordpress.org/plugins/sort-query-posts/#description)
 * [평가](https://ko.wordpress.org/plugins/sort-query-posts/#reviews)
 *  [설치](https://ko.wordpress.org/plugins/sort-query-posts/#installation)
 * [개발](https://ko.wordpress.org/plugins/sort-query-posts/#developers)

 [지원](https://wordpress.org/support/plugin/sort-query-posts/)

## 설명

A really simple and lightweight plugin (73 lines of code – comments included) to
sort posts on-the-fly without making a new query to the database (improves performance).

#### Features:

 * Supports **all `order_by` and `order` values of the [query_posts function](https://codex.wordpress.org/Function_Reference/query_posts#Orderby_Parameters)**
   except `meta_value` and `meta_value_num` (which require a database query).
 * Supports **changing the order of all types of posts**, including custom post 
   type posts and custom post type “archive” posts.

#### Documentation

This plugin adds the function `sort_query_posts_by(string $order_by [, string $order])`
to the global context.
 The second `$order` parameter is optional. Its default value
is `asc` (ascending order).

**Call this function before [the loop](https://codex.wordpress.org/The_Loop) to 
change how posts are ordered.**
 After calling this function you can show the posts
as you normally would.

You can sort posts by:

 * author
 * comment_count
 * date
 * id
 * menu_order
 * modified
 * parent
 * title

This is specially useful in two cases:

 * When you need to reorder the posts returned by the query that WordPress creates
   from your given URL. Custom post type “archive” posts are a great example of 
   this case.
 * When you need the posts returned by your customized query (e.g. `query_posts()`)
   to be shown more than once on the same page and ordered differently.

**Examples:**

    ```
    <?php sort_query_posts_by('title', 'desc'); ?>
    ```

The example above will sort posts by their title in descending order without making
a new query to the database.
 This way sorting is performance friendly.

    ```
    <?php sort_query_posts_by('ID'); ?>
    ```

The example above will sort posts by their ID in ascending order.

    ```
    <?php sort_query_posts_by('rand'); ?>
    ```

The example above will sort posts randomly. When sorting randomly `$order` is ignored.

Plugin developed by Túbal Martín at [www.margenn.com](http://www.margenn.com).

## 설치

 1. Upload `sort-query-posts` folder to the `/wp-content/plugins/` directory
 2. Activate the plugin through the ‘Plugins’ menu in WordPress
 3. Use the added function `sort_query_posts_by` after any wordpress query and your
    posts will be sorted to your needs.

## 후기

이 플러그인에 대한 평가가 없습니다.

## 기여자 & 개발자

“Sort Query Posts”(은)는 오픈 소스 소프트웨어입니다. 다음의 사람들이 이 플러그인에
기여하였습니다.

기여자

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

[자국어로 “Sort Query Posts”(을)를 번역하세요.](https://translate.wordpress.org/projects/wp-plugins/sort-query-posts)

### 개발에 관심이 있으십니까?

[코드 탐색하기](https://plugins.trac.wordpress.org/browser/sort-query-posts/)는,
[SVN 저장소](https://plugins.svn.wordpress.org/sort-query-posts/)를 확인하시거나,
[개발 기록](https://plugins.trac.wordpress.org/log/sort-query-posts/)을 [RSS](https://plugins.trac.wordpress.org/log/sort-query-posts/?limit=100&mode=stop_on_copy&format=rss)
로 구독하세요.

## 변경이력

#### 1.1

 * Code refactored for improved performance. Updating is recommended.

## 기초

 *  버전 **1.1**
 *  최근 업데이트: **14년 전**
 *  활성화된 설치 **100+**
 *  워드프레스 버전 ** 2.5 또는 그 이상 **
 *  다음까지 시험됨: **3.4.2**
 *  언어
 * [English (US)](https://wordpress.org/plugins/sort-query-posts/)
 * 태그:
 * [post](https://ko.wordpress.org/plugins/tags/post/)[query](https://ko.wordpress.org/plugins/tags/query/)
   [reorder](https://ko.wordpress.org/plugins/tags/reorder/)[sort](https://ko.wordpress.org/plugins/tags/sort/)
 *  [고급 보기](https://ko.wordpress.org/plugins/sort-query-posts/advanced/)

## 평점

 별 5점 만점에 5점.

 *  [  3/5-별점 후기     ](https://wordpress.org/support/plugin/sort-query-posts/reviews/?filter=5)
 *  [  0/4-별점 후기     ](https://wordpress.org/support/plugin/sort-query-posts/reviews/?filter=4)
 *  [  0/3-별점 후기     ](https://wordpress.org/support/plugin/sort-query-posts/reviews/?filter=3)
 *  [  0/2-별점 후기     ](https://wordpress.org/support/plugin/sort-query-posts/reviews/?filter=2)
 *  [  0/1-별점 후기     ](https://wordpress.org/support/plugin/sort-query-posts/reviews/?filter=1)

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

[모든  리뷰 보기](https://wordpress.org/support/plugin/sort-query-posts/reviews/)

## 기여자

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

## 지원

할 말 있으신가요? 도움이 필요하신가요?

 [지원 포럼 보기](https://wordpress.org/support/plugin/sort-query-posts/)