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

WordPress Post Distance Filter

설명

Filter posts by distance from a specified location.

This plugin implements simplistic functionality to WordPress posts by enabling archives to be sorted via distances from a specified location when certain URL parameters are detected. You are able to show how far the post’s distance is, and restrict results by a certain radius.

Supports various units of measurement and is customisable too.

Examples of use could be a job search or a store locator.

설치

Setup

Upload the wp-post-distance-filter folder to your plugins directory, then activate the plugin in the Plugins menu. An option should appear under Settings.

Changing Options

On the options page you’ll have a few settings that you can change to make the plugin work to your liking.

  • You can disable all location functionality by disabling it
  • You can change the unit of measurement
  • You can change the URL parameters
  • You can change the name of various meta_keys that the plugin uses when calculating the distance for each post

Specifying Post Locations

To make a post able to be filtered, you must specify the location using a custom field. Enable this at the top of the page.

Then enter the name of your location meta_key and specify the value you want it to show. After updating the post, two more custom fields should appear – the lat and lng keys if done correctly.

Filtering Posts

For any archive page, if the URL location parameter is specified, it will order by distance. You can limit the number of results using the URL radius parameter.

You can show distance information using the_distance(); and get_the_distance(); within the wordpress loop.

if (have_posts()) : while (have_posts()) : the_post();

    the_title();
    the_content();
    the_distance();

endwhile; endif;

FAQ

My posts aren’t filtering

Make sure that your URL parameters are correct and the plugin is enabled.

The latitude and longitude aren’t calculating

Make sure nothing else is using the post’s lat and lng meta_keys. If they are, consider changing their names on the options page.

My posts’s aren’t showing up

Make sure that you’ve specified a location

I can’t see the custom field for location

You need to enable the custom field option by clicking the post dropdown at the very top of the page.

후기

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

기여자 & 개발자

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

기여자

자국어로 “WordPress Post Distance Filter”(을)를 번역하십시오.

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

코드 탐색하기는, SVN 저장소를 확인하시거나, 개발 기록RSS로 구독하십시오.

변경이력

1.1.1

  • Nest plugin under the Settings tab instead

1.1.0

  • Improved options page
  • Latitude and longitude postmeta are now editable
  • Bugfixes

1.0.1

  • Naming conventions

1.0

  • Initial release