Git Product home page Git Product logo

wp-geometa's People

Contributors

mkokes avatar morehawes avatar nciske avatar stuporglue avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

wp-geometa's Issues

Add support for common hard operations

Add functions to handle buffering points in meters/feet with data in EPSG:4326

Add functions to check distance with feet/meters with data in EPSG:4326

Check if wp_geometa_db_version is ahead of WP_GEOMETA_VERSION on dashboard

When someone installs a newer version of wp-geometa-lib it will upgrade their database.

If they later uninstall the plugin that provided the higher version of wp-geometa-lib, there's a chance that the DB changes might not be optimal or compatible. Warn them on the dashboard if that's the case.

PHP Warnings

The following warnings are thrown on pages that utilize spatial functions in WP Query:

Warning: Use of undefined constant WP_GEOMETA_DEBUG - assumed 'WP_GEOMETA_DEBUG' (this will throw an Error in a future version of PHP) in ...../public_html/wp-content/plugins/wp-geometa/lib/wp-geometa-lib/wp-geoquery.php on line 182

Warning: Use of undefined constant WP_GEOMETA_DEBUG - assumed 'WP_GEOMETA_DEBUG' (this will throw an Error in a future version of PHP) in ...../public_html/wp-content/plugins/wp-geometa/lib/wp-geometa-lib/wp-geoquery.php on line 250

Warning: Use of undefined constant WP_GEOMETA_DEBUG - assumed 'WP_GEOMETA_DEBUG' (this will throw an Error in a future version of PHP) in ...../public_html/wp-content/plugins/wp-geometa/lib/wp-geometa-lib/wp-geoquery.php on line 128

PHP Notices

The following notices are thrown on all pages (admin and front-end):

Notice: Undefined variable: wp_geometa_version in ...../public_html/wp-content/plugins/wp-geometa/lib/wp-geometa-lib/wp-geometa-lib.php on line 34

Notice: Undefined variable: wp_geometa_max_version in ...../public_html/wp-content/plugins/wp-geometa/lib/wp-geometa-lib/wp-geometa-lib.php on line 34

How can this be fixed?

Regression tests failing with mysql 8.0.4

I run regression tests as data is not saved in the tables and tests are failing. I see that data is not saved in the _geo tables, I tried adding a field with acf but spatial data is not saved. I tested the same thing locally with 5.7 and it worked, so wondering if this might be an 8.0.4 issue.

image

Let plugins enable the dashboard

Move the dashboard initialization into a function so that whichever WP-GeoMeta ends up active will also provide the dashboard.

Add a function so that other plugins can enable the dashboard if WP-GeoMeta is only used as a library.

Error "File Path Not Found"

Hi,
I have recently installed WP-GeoMeta but I get the following error when I want to import the .geojason. What is the problem with that? Can someone check it?
Thanks...

Selection_432

Fatal error with version 0.4.0

A geoquery is no longer functioning on our site (possibly related to PHP 8 compatibility?). The plugin version here on GitHub (0.4.0) is not the same as in the WordPress.org repository (0.3.5) so I tried updating the plugin to version 0.4.0 found here but I'm getting the following PHP fatal error.

PHP Fatal error:  Uncaught Error: Undefined constant "WP_GEOMETA_DEBUG" in /public/wp-content/plugins/wp-geometa/lib/wp-geometa-lib/wp-geoquery.php:182

Make dashboard only show counts for posts users can see

Instead of using

add_management_page( 'WP-GeoMeta', 'WP-GeoMeta', 'install_plugins', 'wp-geometa', array( $this, 'show_dashboard' ) );

Always add the page to the Tools menu, and then use capabilities to filter which spatial records and counts users can see.

Global distance search issues

First off, absolutely great plugin, Well done. Hopefully, you can help with a problem that I am having.

The goal is to search for photographers from a point(latitude and longitude) and order the results by distance from that center point. The below code works great, however, we are getting limited results. For example, if I do a search from the center point Bangkok Thailand, we are only getting photographers in Asia, and not in North America. The same results happen when doing a search in North America, no Asia photographers. I thought by increasing the mile radius (some large number like 24,901 miles) would solve this problem, but it results in no results. So the goal is to do a global search. Am I missing something? Thanks!

CODE USED

WP_GeoUtil::wp_buffer_point_mi($center_point,10000,8);
$results = new WP_Query( array(
'post_type'=> 'photographer',
'orderby' => 'distance',
'order' => 'ASC',
'meta_query' => array(
'inbuffer' => array(
'key' => 'location',
'compare' => 'ST_INTERSECTS',
'value' => $buffered_shape
),
'distance' => array(
'key' => 'location',
'compare' => 'ST_DISTANCE',
'value' => $center_point,
'type' => 'DECIMAL(10,7)'
)
),
));

Let devs only enable for specific meta keys

Let developers set up WP-GeoMeta so that it's only listening for the data they're storing.

There's no reason to listen to every meta update if we only need it for a certain post type or something.

Create Lat/Lng migration tool

Possibly a separate plugin, or at least only available in the dashboard.

Let users specify a post type and fields to use as lat/lng to convert to geometry.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.