Skip to content

Instantly share code, notes, and snippets.

@mgibbs189
Created September 12, 2016 12:41
Show Gist options
  • Select an option

  • Save mgibbs189/5a2d67b1a28cab9ac72d0c441b9b5fe7 to your computer and use it in GitHub Desktop.

Select an option

Save mgibbs189/5a2d67b1a28cab9ac72d0c441b9b5fe7 to your computer and use it in GitHub Desktop.
FacetWP - sort by proximity distance
<?php
return array(
"post_type" => "job_listing",
"post_status" => "publish",
"orderby" => "post__in",
"order" => "ASC",
"posts_per_page" => 10
);
@thinkholmes
Copy link

Thank you for sharing this! I got stuck trying to order some listings by proximity distance and this worked great.

@Mohaesse
Copy link

Hello @thinkholmes,
I added these options on my wp_query but it does not work please tell me where exactly I can put this code

@DavidSteinbauer
Copy link

@Mohaesse Please put in
2018-05-16 at 15 12

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment