Changeset 12700 for extensions/rv_gmaps/trunk/admin/admin_config.php
- Timestamp:
- Dec 7, 2011, 5:39:56 AM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/rv_gmaps/trunk/admin/admin_config.php
r8367 r12700 6 6 if ( isset($_POST['submit']) ) 7 7 { 8 $query = ' 8 if (isset($_POST['gmaps_api_key'])) 9 { 10 $query = ' 9 11 UPDATE '.CONFIG_TABLE.' 10 12 SET value="'.$_POST['gmaps_api_key'].'" 11 13 WHERE param="gmaps_api_key" 12 14 LIMIT 1'; 13 pwg_query($query); 14 list($conf['gmaps_api_key']) = array_from_query('SELECT value FROM '.CONFIG_TABLE.' WHERE param="gmaps_api_key"', 'value'); 15 pwg_query($query); 16 list($conf['gmaps_api_key']) = array_from_query('SELECT value FROM '.CONFIG_TABLE.' WHERE param="gmaps_api_key"', 'value'); 17 } 15 18 19 if (isset($_POST['gmaps_auto_sync'])) 20 { 21 conf_update_param('gmaps_auto_sync', "1"); 22 $conf['gmaps_auto_sync']=1; 23 } 24 else 25 { 26 $query = 'DELETE FROM '.CONFIG_TABLE.' WHERE param="gmaps_auto_sync"'; 27 pwg_query($query); 28 unset($conf['gmaps_auto_sync']); 29 } 30 16 31 $gm_config = rvm_get_config(); 17 32 … … 42 57 'NB_GEOTAGGED' => $nb_geotagged, 43 58 'GMAPS_API_KEY' => $conf['gmaps_api_key'], 59 'GMAPS_AUTO_SYNC' => isset($conf['gmaps_auto_sync']) ? 1:0, 44 60 'NB_MARKERS' => rvm_get_config_var('nb_markers',40), 45 61 'NB_IMAGES_PER_MARKER' => rvm_get_config_var('nb_images_per_marker',20),
Note: See TracChangeset
for help on using the changeset viewer.