| 1 |
<?php |
| 2 |
if ( ! defined( 'ABSPATH' ) ) { |
| 3 |
exit; |
| 4 |
} |
| 5 |
?> |
| 6 |
<div data-columns="8"> |
| 7 |
<!-- to save api key--> |
| 8 |
<div class="wpgmapembed_get_api_key"> |
| 9 |
<div class="error"> |
| 10 |
<p style="font-size:17px;"> |
| 11 |
<strong><?php _e( 'Notice: The plugin requires following API key.', 'gmap-embed' ); ?></strong></p> |
| 12 |
<form method="post" action="<?php echo admin_url(); ?>admin.php?page=wpgmapembed&message=3"> |
| 13 |
|
| 14 |
<p><?php _e( 'Enter API Key', 'gmap-embed' ); ?> <input type="text" name="wpgmapembed_key" |
| 15 |
value="<?php echo esc_html( get_option( 'wpgmap_api_key' ) ); ?>" |
| 16 |
size="45"> |
| 17 |
<button class="wd-btn wd-btn-primary button media-button button-primary"><?php _e( 'Save', 'gmap-embed' ); ?></button> |
| 18 |
|
| 19 |
<a target="_blank" |
| 20 |
href="https://console.developers.google.com/flows/enableapi?apiid=maps_backend,places_backend,geolocation,geocoding_backend,directions_backend&keyType=CLIENT_SIDE&reusekey=true" |
| 21 |
class="button media-button button-default button-large"><?php _e( 'GET FREE API KEY', 'gmap-embed' ); ?></a> |
| 22 |
<br/><?php _e( 'The API key may take up to 5 minutes to take effect', 'gmap-embed' ); ?> |
| 23 |
</p> |
| 24 |
</form> |
| 25 |
|
| 26 |
<form method="post" action="<?php echo admin_url(); ?>admin.php?page=wpgmapembed&message=4"> |
| 27 |
<p><?php _e( 'License Key: ', 'gmap-embed' ); ?> <input type="text" name="wpgmapembed_license" |
| 28 |
value="<?php echo esc_html( get_option( 'wpgmapembed_license' ) ); ?>" |
| 29 |
size="45"> |
| 30 |
<button class="wd-btn wd-btn-primary button media-button button-primary"><?php _e( 'Save', 'gmap-embed' ); ?></button> |
| 31 |
|
| 32 |
<?php |
| 33 |
if ( strlen( trim( get_option( 'wpgmapembed_license' ) ) ) !== 32 ) { ?> |
| 34 |
<a target="_blank" |
| 35 |
href="https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=WVPQNC6CJ6T4Q" |
| 36 |
class="button media-button button-default button-large"><?php _e( 'GET LICENSE KEY', 'gmap-embed' ); ?></a> |
| 37 |
<?php |
| 38 |
} |
| 39 |
?> |
| 40 |
</p> |
| 41 |
</form> |
| 42 |
|
| 43 |
</div> |
| 44 |
</div> |
| 45 |
</div> |