The plugin is great, so far works perfectly, but I've stumbled upon a problem while tweaking it for some additional functionalities. I'm afraid I need some tips from the experts
I wanted my guests (not users, but normal, frontend visitors) to be able to add their companies to the map using a simple form. I've installed WP User Frontend plugin and used it to create a custom form and I've succesfully used it to create a new landmark with title, description and icon loaded from the form. However I cannot load the address.
Here is the code fragment I placed in the form PHP file:
<li id="bgmp-placemark-coordinates"> <label for="bgmp_address"><?php _e( 'Address:', 'bgmp' ); ?></label> <input id="bgmp_address" class="requiredField" type="text" value="<?php echo $address; ?>" name="bgmp_address"> <?php if( $showGeocodeResults ) : ?> <em><?php printf( __( '(Geocoded to: %f, %f)', 'bgmp' ), $latitude, $longitude ); ?></em> <?php elseif( $showGeocodeError ) : ?> <em><?php _e( "(Error geocoding address. Please make sure it's correct and try again.)", 'bgmp' ); ?></em> <?php endif; ?> </li>
I also modiefied core.php in the line 761, by adding a second 'require_once' function:
require_once( dirname( __FILE__ ) . '/views/meta-address.php' ); require_once('/wp-content/plugins/wp-user-frontend/wpuf-add-post.php');
Thus far, after each new placemark added through the form I'm getting such a warning in Placemarks management page in wp-admin:
That address couldn't be geocoded, please make sure that it's correct. Geocode response: stdClass Object ( [results] => Array ( ) [status] => ZERO_RESULTS )
I don't know PHP, so I have trouble pinpointing the issue. What am I missing? What did I do wrong? What should I try? Are there any workaround? I'm open to all and any suggestions at this point.
Thanks in advance,