Changeset 643415
- Timestamp:
- 12/22/2012 03:02:55 PM (13 years ago)
- Location:
- google-routeplaner/trunk
- Files:
-
- 11 added
- 10 edited
-
google-routeplaner-add-route.php (modified) (7 diffs)
-
google-routeplaner-doc-page.php (modified) (1 diff)
-
google-routeplaner-edit-route.php (modified) (6 diffs)
-
google-routeplaner-js.php (modified) (1 diff)
-
google-routeplaner-list-routes.php (modified) (1 diff)
-
google-routeplaner-main-page.php (modified) (2 diffs)
-
google-routeplaner-pages.php (modified) (3 diffs)
-
google-routeplaner-settings-page.php (modified) (2 diffs)
-
google-routeplaner.php (modified) (7 diffs)
-
languages (added)
-
languages/google_routeplaner-de_DE.mo (added)
-
languages/google_routeplaner-de_DE.po (added)
-
languages/google_routeplaner-fr_FR.mo (added)
-
languages/google_routeplaner-fr_FR.po (added)
-
languages/google_routeplaner-nl_NL.mo (added)
-
languages/google_routeplaner-nl_NL.po (added)
-
languages/google_routeplaner-ro_RO.mo (added)
-
languages/google_routeplaner-ro_RO.po (added)
-
languages/google_routeplaner-sk_SK.mo (added)
-
languages/google_routeplaner-sk_SK.po (added)
-
readme.txt (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
google-routeplaner/trunk/google-routeplaner-add-route.php
r604752 r643415 8 8 { 9 9 10 $wpdb->query("INSERT INTO " . $wpdb->prefix . "google_routeplaner (`start_location`, `planer_width`, `planer_ height`, `planer_zoom`, `planer_type`, `planer_zoom_control`, `planer_type_control`, `planer_language`)10 $wpdb->query("INSERT INTO " . $wpdb->prefix . "google_routeplaner (`start_location`, `planer_width`, `planer_width_unit`, `planer_height`, `planer_height_unit`, `planer_zoom`, `planer_type`, `planer_zoom_control`, `planer_type_control`, `planer_autofill`, `planer_language`) 11 11 VALUES ( 12 12 '" . $_POST['google_routeplaner_destination'] . "', 13 13 '" . $_POST['google_routeplaner_map_width'] . "', 14 '" . $_POST['google_routeplaner_map_width_unit'] . "', 14 15 '" . $_POST['google_routeplaner_map_height'] . "', 16 '" . $_POST['google_routeplaner_map_height_unit'] . "', 15 17 '" . $_POST['google_routeplaner_zoom'] . "', 16 18 '" . $_POST['google_routeplaner_map_type'] . "', 17 19 '" . $_POST['google_routeplaner_zoom_control'] . "', 18 20 '" . $_POST['google_routeplaner_type_control'] . "', 21 '" . $_POST['google_routeplaner_autofill'] . "', 19 22 '" . $_POST['google_routeplaner_language'] . "')"); 20 23 … … 25 28 ?> 26 29 <div class="wrap google_routeplaner"> 27 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplan er', 'google_routeplaner'); ?> • <?php _e('Add Route', 'google_routeplaner'); ?></h2>30 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplanner', 'google_routeplaner'); ?> • <?php _e('Add Route', 'google_routeplaner'); ?></h2> 28 31 <p class="error"> 29 32 <?php _e('There has been a problem with installing the plugin. The plugin tried to fix this, please try again.'); ?><br /> … … 35 38 ?> 36 39 <div class="wrap google_routeplaner"> 37 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplan er', 'google_routeplaner'); ?> • <?php _e('Add Route', 'google_routeplaner'); ?></h2>40 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplanner', 'google_routeplaner'); ?> • <?php _e('Add Route', 'google_routeplaner'); ?></h2> 38 41 <p class="success"><?php _e('Your route has been saved!', 'google_routeplaner'); ?><br /> 39 42 <?php _e('The code for this route is: ', 'google_routeplaner'); ?> [googlerouteplaner=<?php echo $map_id; ?>]</p> … … 49 52 ?> 50 53 <div class="wrap google_routeplaner"> 51 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplan er', 'google_routeplaner'); ?> • <?php _e('Add Route', 'google_routeplaner'); ?></h2>54 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplanner', 'google_routeplaner'); ?> • <?php _e('Add Route', 'google_routeplaner'); ?></h2> 52 55 <div id="poststuff"> 53 56 <form method="post" action=""> … … 95 98 <i><?php _e('Add a search string for the destination. Adress, company name or something like this.', 'google_routeplaner'); ?></i></p> 96 99 <p><label for="google_routeplaner_map_width" class="formbold"><?php _e('Map width', 'google_routeplaner'); ?></label><br /> 97 <input type="text" name="google_routeplaner_map_width" id="google_routeplaner_map_width" style="width: 70px;" value="500" /><br /> 100 <input type="text" name="google_routeplaner_map_width" id="google_routeplaner_map_width" style="width: 70px;" value="500" /> 101 <select name="google_routeplaner_map_width_unit" id="google_routeplaner_map_width_unit"> 102 <option value="px">px</option> 103 <option value="%">%</option> 104 <option value="em">em</option> 105 </select> 106 <br /> 98 107 <i><?php _e('Enter the width for the map.', 'google_routeplaner'); ?></i></p> 99 108 <p><label for="google_routeplaner_map_height" class="formbold"><?php _e('Map heigth', 'google_routeplaner'); ?></label><br /> 100 <input type="text" name="google_routeplaner_map_height" id="google_routeplaner_map_height" style="width: 70px;" value="400" /><br /> 109 <input type="text" name="google_routeplaner_map_height" id="google_routeplaner_map_height" style="width: 70px;" value="400" /> 110 <select name="google_routeplaner_map_height_unit" id="google_routeplaner_map_height_unit"> 111 <option value="px">px</option> 112 <option value="%">%</option> 113 <option value="em">em</option> 114 </select> 115 <br /> 101 116 <i><?php _e('Enter the height for the map.', 'google_routeplaner'); ?></i></p> 102 117 … … 117 132 </select></p> 118 133 134 <p><span class="formbold"><?php _e('Auto-Detect users location', 'google_routeplaner'); ?></span><br /> 135 <input type="radio" name="google_routeplaner_autofill" id="google_routeplaner_autofill_yes" value="1" /> 136 <label for="google_routeplaner_autofill_yes"><?php _e('Yes', 'google_routeplaner'); ?></label><br /> 137 <input type="radio" name="google_routeplaner_autofill" id="google_routeplaner_autofill_no" value="0" checked="checked" /> 138 <label for="google_routeplaner_autofill_no"><?php _e('No', 'google_routeplaner'); ?></label><br /> 139 <i><?php _e('This is based on HTML5 and will work best with mobile devices.', 'google_routeplaner'); ?></i></p> 140 119 141 <p><label for="google_routeplaner_language" class="formbold"><?php _e('Language', 'google_routeplaner'); ?></label><br /> 120 142 <select name="google_routeplaner_language" id="google_routeplaner_language"> … … 131 153 <option value="ru"<?php if('ru' == get_option("google_routeplaner_language")) { echo ' selected="selected"'; } ?>><?php _e('Russian', 'google_routeplaner'); ?></option> 132 154 <option value="ja"<?php if('ja' == get_option("google_routeplaner_language")) { echo ' selected="selected"'; } ?>><?php _e('Japanese', 'google_routeplaner'); ?></option> 133 </select></p> 155 </select><br /> 156 <i><?php _e('This only effects the route output, not the interface!', 'google_routeplaner'); ?></i></p> 134 157 </div> 135 158 </div> -
google-routeplaner/trunk/google-routeplaner-doc-page.php
r594932 r643415 1 1 <div class="wrap google_routeplaner"> 2 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplan er', 'google_routeplaner'); ?> • <?php _e('Documentation', 'google_routeplaner'); ?></h2>2 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplanner', 'google_routeplaner'); ?> • <?php _e('Documentation', 'google_routeplaner'); ?></h2> 3 3 <div id="poststuff"> 4 4 <div class="postbox"> -
google-routeplaner/trunk/google-routeplaner-edit-route.php
r604752 r643415 12 12 start_location = '" . $_POST['google_routeplaner_destination'] . "', 13 13 planer_width = '" . $_POST['google_routeplaner_map_width'] . "', 14 planer_width_unit = '" . $_POST['google_routeplaner_map_width_unit'] . "', 14 15 planer_height = '" . $_POST['google_routeplaner_map_height'] . "', 16 planer_height_unit = '" . $_POST['google_routeplaner_map_height_unit'] . "', 15 17 planer_zoom = '" . $_POST['google_routeplaner_zoom'] . "', 16 18 planer_type = '" . $_POST['google_routeplaner_map_type'] . "', 17 19 planer_zoom_control = '" . $_POST['google_routeplaner_zoom_control'] . "', 18 20 planer_type_control = '" . $_POST['google_routeplaner_type_control'] . "', 21 planer_autofill = '" . $_POST['google_routeplaner_autofill'] . "', 19 22 planer_language = '" . $_POST['google_routeplaner_language'] . "' 20 23 WHERE planer_id = '" . $_POST['route_id'] . "' LIMIT 1"); … … 22 25 ?> 23 26 <div class="wrap google_routeplaner"> 24 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplan er', 'google_routeplaner'); ?> • <?php _e('Edit Route', 'google_routeplaner'); ?></h2>27 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplanner', 'google_routeplaner'); ?> • <?php _e('Edit Route', 'google_routeplaner'); ?></h2> 25 28 <p class="success"><?php _e('Your changes has been saved!', 'google_routeplaner'); ?></p> 26 29 <p><a href="admin.php?page=google_routeplaner_routes"><?php _e('Back to overview', 'google_routeplaner'); ?></a></p> … … 36 39 ?> 37 40 <div class="wrap google_routeplaner"> 38 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplan er', 'google_routeplaner'); ?> • <?php _e('Edit Route', 'google_routeplaner'); ?></h2>41 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplanner', 'google_routeplaner'); ?> • <?php _e('Edit Route', 'google_routeplaner'); ?></h2> 39 42 <div id="poststuff"> 40 43 <form method="post" action=""> … … 102 105 <i><?php _e('Add a search string for the destination. Adress, company name or something like this.', 'google_routeplaner'); ?></i></p> 103 106 <p><label for="google_routeplaner_map_width" class="formbold"><?php _e('Map width', 'google_routeplaner'); ?></label><br /> 104 <input type="text" name="google_routeplaner_map_width" id="google_routeplaner_map_width" style="width: 70px;" value="<?php echo $planer['planer_width']; ?>" /><br /> 107 <input type="text" name="google_routeplaner_map_width" id="google_routeplaner_map_width" style="width: 70px;" value="<?php echo $planer['planer_width']; ?>" /> 108 <select name="google_routeplaner_map_width_unit" id="google_routeplaner_map_width_unit"> 109 <option value="px"<?php if('px' == $planer['planer_width_unit']) { echo ' selected=""'; } ?>>px</option> 110 <option value="%"<?php if('%' == $planer['planer_width_unit']) { echo ' selected=""'; } ?>>%</option> 111 <option value="em"<?php if('em' == $planer['planer_width_unit']) { echo ' selected=""'; } ?>>em</option> 112 </select> 113 <br /> 105 114 <i><?php _e('Enter the width for the map.', 'google_routeplaner'); ?></i></p> 106 115 <p><label for="google_routeplaner_map_height" class="formbold"><?php _e('Map heigth', 'google_routeplaner'); ?></label><br /> 107 <input type="text" name="google_routeplaner_map_height" id="google_routeplaner_map_height" style="width: 70px;" value="<?php echo $planer['planer_height']; ?>" /><br /> 116 <input type="text" name="google_routeplaner_map_height" id="google_routeplaner_map_height" style="width: 70px;" value="<?php echo $planer['planer_height']; ?>" /> 117 <select name="google_routeplaner_map_height_unit" id="google_routeplaner_map_height_unit"> 118 <option value="px"<?php if('px' == $planer['planer_height_unit']) { echo ' selected=""'; } ?>>px</option> 119 <option value="%"<?php if('%' == $planer['planer_height_unit']) { echo ' selected=""'; } ?>>%</option> 120 <option value="em"<?php if('em' == $planer['planer_height_unit']) { echo ' selected=""'; } ?>>em</option> 121 </select> 122 <br /> 108 123 <i><?php _e('Enter the height for the map.', 'google_routeplaner'); ?></i></p> 109 124 … … 124 139 </select></p> 125 140 126 <p> <label for="google_routeplaner_language" class="formbold"><?php _e('Language', 'google_routeplaner'); ?></label><br /> 141 142 <p><span class="formbold"><?php _e('Auto-Detect users location', 'google_routeplaner'); ?></span><br /> 143 <input type="radio" name="google_routeplaner_autofill" id="google_routeplaner_autofill_yes" value="1"<?php if(1 == intval($planer['planer_autofill'])) { echo ' checked=""'; } ?> /> 144 <label for="google_routeplaner_autofill_yes"><?php _e('Yes', 'google_routeplaner'); ?></label><br /> 145 <input type="radio" name="google_routeplaner_autofill" id="google_routeplaner_autofill_no" value="0"<?php if(0 == intval($planer['planer_autofill'])) { echo ' checked=""'; } ?> /> 146 <label for="google_routeplaner_autofill_no"><?php _e('No', 'google_routeplaner'); ?></label><br /> 147 <i><?php _e('This is based on HTML5 and will work best with mobile devices.', 'google_routeplaner'); ?></i></p> 148 149 <p><label for="google_routeplaner_language" class="formbold"><?php _e('Language', 'google_routeplaner'); ?></label><br /> 127 150 <select name="google_routeplaner_language" id="google_routeplaner_language"> 128 151 <option value=""><?php _e('Default', 'google_routeplaner'); ?></option> … … 138 161 <option value="ru"<?php if('ru' == $planer['planer_language']) { echo ' selected="selected"'; } ?>><?php _e('Russian', 'google_routeplaner'); ?></option> 139 162 <option value="ja"<?php if('ja' == $planer['planer_language']) { echo ' selected="selected"'; } ?>><?php _e('Japanese', 'google_routeplaner'); ?></option> 140 </select></p> 163 </select><br /> 164 <i><?php _e('This only effects the route output, not the interface!', 'google_routeplaner'); ?></i></p> 141 165 </div> 142 166 </div> -
google-routeplaner/trunk/google-routeplaner-js.php
r594932 r643415 8 8 window.addEventListener("load", initialize' . $_GET['planer_id'] . ', false); 9 9 }'; 10 11 if(1 == intval($_GET['autofill'])) { 12 13 echo 'function setUserPos(position) { 14 document.getElementById(\'fromAddress' . $_GET['planer_id'] . '\').value = position.coords.latitude + \', \' + position.coords.longitude; 15 //alert(position.coords.latitude); 16 //alert(position.coords.longitude); 17 } 10 18 19 navigator.geolocation.getCurrentPosition(setUserPos);'; 20 } 21 11 22 ?> -
google-routeplaner/trunk/google-routeplaner-list-routes.php
r604752 r643415 17 17 } 18 18 </script> 19 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplan er', 'google_routeplaner'); ?> • <?php _e('Routes', 'google_routeplaner'); ?></h2>19 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplanner', 'google_routeplaner'); ?> • <?php _e('Routes', 'google_routeplaner'); ?></h2> 20 20 <p><a href="admin.php?page=google_routeplaner_routes&routeplaner_action=google_routeplaner_add_route" class="button-primary"><?php _e('Create Route', 'google_routeplaner'); ?></a></p> 21 21 <table class="widefat" cellspacing="0" cellpadding="0"> -
google-routeplaner/trunk/google-routeplaner-main-page.php
r604752 r643415 1 1 <div class="wrap google_routeplaner"> 2 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplan er', 'google_routeplaner'); ?> • <?php _e('Overview', 'google_routeplaner'); ?></h2>2 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplanner', 'google_routeplaner'); ?> • <?php _e('Overview', 'google_routeplaner'); ?></h2> 3 3 <div id="poststuff"> 4 4 <div class="postbox" style="width: 30%; float: right;"> 5 5 <h3><?php _e('Changelog', 'google_routeplaner'); ?></h3> 6 6 <div class="inside" style="height: 300px; overflow: auto; overflow-y: scroll;"> 7 <h5>Version 2.5</h5> 8 <ul> 9 <li>French translation added, thanks to Corentin Smith</li> 10 <li>Slovak Translation by <a href="http://webhostinggeeks.com/blog/">WebHostingGeeks.com</a> added</li> 11 <li>You can now define map height and width in px, % or em</li> 12 <li>New feature: HTML5 detection for users location to autofill the form</li> 13 </ul> 7 14 <h5>Version 2.3</h5> 8 15 <ul> … … 75 82 <h3><?php _e('The Plugin', 'google_routeplaner'); ?></h3> 76 83 <div class="inside"> 77 <p><?php _e('Google Routeplan er generates a routeplaner based on the <a href="http://code.google.com/apis/maps/">Google Maps API</a>.', 'google_routeplaner'); ?></p>84 <p><?php _e('Google Routeplanner generates a routeplanner based on the <a href="http://code.google.com/apis/maps/">Google Maps API</a>.', 'google_routeplaner'); ?></p> 78 85 <p><?php _e('We suggest adding a printer friendly stylesheet to your Wordpress design to allow your users to print the route without the need to print design elements. A tutorial how to do this can be found <a href="http://codex.wordpress.org/Styling_for_Print">here</a>.', 'google_routeplaner'); ?></p> 79 86 <p><?php _e('Plugin developed by <a href="http://deformed-design.de">Deformed Design</a>.', 'google_routeplaner'); ?></p> -
google-routeplaner/trunk/google-routeplaner-pages.php
r604752 r643415 61 61 ?> 62 62 <div class="wrap google_routeplaner"> 63 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplan er', 'google_routeplaner'); ?> • <?php _e('Delete Route', 'google_routeplaner'); ?></h2>63 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplanner', 'google_routeplaner'); ?> • <?php _e('Delete Route', 'google_routeplaner'); ?></h2> 64 64 <p class="success"><?php _e('The route has been deleted!', 'google_routeplaner'); ?></p> 65 65 <p><a href="admin.php?page=google_routeplaner_routes" class="button"><?php _e('Back to overview', 'google_routeplaner'); ?></a></p> … … 74 74 ?> 75 75 <div class="wrap google_routeplaner"> 76 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplan er', 'google_routeplaner'); ?> • <?php _e('Preview Route', 'google_routeplaner'); ?></h2>76 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplanner', 'google_routeplaner'); ?> • <?php _e('Preview Route', 'google_routeplaner'); ?></h2> 77 77 <p><a href="admin.php?page=google_routeplaner_routes" class="button"><?php _e('Back to overview', 'google_routeplaner'); ?></a></p> 78 78 <?php echo google_routeplaner_build_map($route_id); ?> … … 110 110 add_option("google_routeplaner_donate","personal_link"); 111 111 add_option("google_routeplaner_language","en"); 112 add_option("google_routeplaner_version","2.5"); 112 113 113 114 add_action( 'admin_menu' , 'admin_menu_new_items' ); -
google-routeplaner/trunk/google-routeplaner-settings-page.php
r594932 r643415 1 1 <div class="wrap google_routeplaner"> 2 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplan er', 'google_routeplaner'); ?> • <?php _e('Settings', 'google_routeplaner'); ?></h2>2 <div id="icon-google_routeplaner" class="icon32"><br /></div><h2><?php _e('Google Routeplanner', 'google_routeplaner'); ?> • <?php _e('Settings', 'google_routeplaner'); ?></h2> 3 3 <?php 4 4 /* … … 55 55 <option value="ja"<?php if('ja' == get_option("google_routeplaner_language")) { echo ' selected="selected"'; } ?>><?php _e('Japanese', 'google_routeplaner'); ?></option> 56 56 </select><br /> 57 <i><?php _e('Set language for driving information .', 'google_routeplaner'); ?></i></p>57 <i><?php _e('Set language for driving information, this does not effect the interface.', 'google_routeplaner'); ?></i></p> 58 58 </div> 59 59 </div> -
google-routeplaner/trunk/google-routeplaner.php
r604752 r643415 1 1 <?php 2 2 /* 3 Plugin Name: Google Routeplan er3 Plugin Name: Google Routeplanner 4 4 Plugin URI: http://support.derwebschmied.de 5 5 Description: Allows you to add one or more route planners based on Google Maps to help your users to find a specific place. 6 Version: 2. 36 Version: 2.5 7 7 Author: DerWebschmied 8 8 Author URI: http://support.derwebschmied.de … … 15 15 * Load Language 16 16 */ 17 load_plugin_textdomain('google_routeplaner', WP_PLUGIN_DIR . '/google-routeplaner/', dirname(plugin_basename(__FILE__)) );17 load_plugin_textdomain('google_routeplaner', WP_PLUGIN_DIR . '/google-routeplaner/', dirname(plugin_basename(__FILE__)) . '/languages/'); 18 18 19 19 /* … … 72 72 `start_location` VARCHAR(120) NOT NULL, 73 73 `planer_width` INT NOT NULL, 74 `planer_width_unit` VARCHAR( 5 ) DEFAULT \'px\', 74 75 `planer_height` INT NOT NULL, 76 `planer_height_unit` VARCHAR( 5 ) DEFAULT \'px\', 75 77 `planer_zoom` INT NOT NULL, 76 78 `planer_type` VARCHAR(120) NOT NULL, 77 79 `planer_zoom_control` VARCHAR(120) NOT NULL, 78 80 `planer_type_control` VARCHAR(120) NOT NULL, 81 `planer_autofill` INT NOT NULL DEFAULT \'0\', 79 82 `planer_language` VARCHAR( 2 ), 80 83 PRIMARY KEY (`planer_id`) … … 83 86 84 87 } else { 85 /* 86 * Update old information in the database for version 2 87 */ 88 $wpdb->query('ALTER TABLE `' . $wpdb->prefix . 'google_routeplaner` ADD `planer_zoom` INT NOT NULL DEFAULT \'8\' AFTER `planer_height`'); 88 google_routeplaner_update(); 89 } 90 } 91 92 function google_routeplaner_update() { 93 /* 94 * Update old information in the database for version 2 95 */ 96 $wpdb->query('ALTER TABLE `' . $wpdb->prefix . 'google_routeplaner` ADD `planer_zoom` INT NOT NULL DEFAULT \'8\' AFTER `planer_height`'); 89 97 90 /* 91 * Update old information in the database for version 2.2 92 */ 93 $cur_donate = get_option('google_routeplaner_donate'); 94 if('link' == $cur_donate) { 95 update_option("google_routeplaner_donate", 'personal_link'); 96 } elseif('articel' == $cur_donate) { 97 update_option("google_routeplaner_donate", 'personal_no_link'); 98 } elseif('paypal' == $cur_donate) { 99 update_option("google_routeplaner_donate", 'commercial_paypal'); 100 } elseif('none' == $cur_donate) { 101 update_option("google_routeplaner_donate", 'personal_no_link'); 102 } 103 104 105 } 106 } 98 /* 99 * Update old information in the database for version 2.2 100 */ 101 $cur_donate = get_option('google_routeplaner_donate'); 102 if('link' == $cur_donate) { 103 update_option("google_routeplaner_donate", 'personal_link'); 104 } elseif('articel' == $cur_donate) { 105 update_option("google_routeplaner_donate", 'personal_no_link'); 106 } elseif('paypal' == $cur_donate) { 107 update_option("google_routeplaner_donate", 'commercial_paypal'); 108 } elseif('none' == $cur_donate) { 109 update_option("google_routeplaner_donate", 'personal_no_link'); 110 } 111 112 /* 113 * Update old information in the database for version 2.5 114 */ 115 $wpdb->query('ALTER TABLE `wp_google_routeplaner` ADD `planer_width_unit` VARCHAR( 5 ) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL DEFAULT \'px\' AFTER `planer_width`'); 116 $wpdb->query('ALTER TABLE `wp_google_routeplaner` ADD `planer_height_unit` VARCHAR( 5 ) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL DEFAULT \'px\' AFTER `planer_height`'); 117 $wpdb->query('ALTER TABLE `wp_google_routeplaner` ADD `planer_autofill` INT NOT NULL DEFAULT \'0\' AFTER `planer_type_control`'); 118 119 120 } 121 107 122 if ( function_exists('register_update_hook') ) 108 register_update_hook(WP_PLUGIN_DIR . '/google-routeplaner/google-routeplaner.php', 'google_routeplaner_ install');123 register_update_hook(WP_PLUGIN_DIR . '/google-routeplaner/google-routeplaner.php', 'google_routeplaner_update'); 109 124 110 125 /* … … 199 214 $map .= '<script type="text/javascript" src="' . WP_PLUGIN_URL . '/google-routeplaner/google-routeplaner-main-js.php?planer_id=' . $planer['planer_id'] . '&planer_type=' . urlencode($planer['planer_type']) . '&planer_zoom_control=' . urlencode($planer['planer_zoom_control']) . '&planer_type_control=' . urlencode($planer['planer_type_control']) . '&start_location=' . urlencode($planer['start_location']) . '&planer_zoom=' . $planer['planer_zoom'] . '"></script>' . "\n"; 200 215 201 if('' !== $planer['planer_css'] && strlen($planer['planer_css']) > 55) {202 $map .= '<style type="text/css" media="all">203 ' . $planer['planer_css'] . '204 </style>' . "\n";205 }206 207 216 $map .= 208 217 '<form action="#" onsubmit="calcRoute' . $planer['planer_id'] . '(); return false"> 209 218 <div id="map_controls' . $planer['planer_id'] . '" class="google_map_controls"><label for="fromAddress' . $planer['planer_id'] . '">' . __('Your location', 'google_routeplaner') . '</label> <input type="text" size="25" id="fromAddress' . $planer['planer_id'] . '" name="from" value=""/><input name="calc" type="submit" value="' . __('Create route', 'google_routeplaner') . '" /></div> 210 <div id="map_canvas' . $planer['planer_id'] . '" class="google_map_canvas" style="overflow: hidden; width: ' . $planer['planer_width'] . 'px; height: ' . $planer['planer_height'] . 'px;"></div>219 <div id="map_canvas' . $planer['planer_id'] . '" class="google_map_canvas" style="overflow: hidden; width: ' . $planer['planer_width'] . $planer['planer_width_unit'] . '; height: ' . $planer['planer_height'] . $planer['planer_height_unit'] . ';"></div> 211 220 <div id="map_directions' . $planer['planer_id'] . '" class="google_map_directions"></div> 212 221 </form>' . "\n"; 213 222 214 $map .= '<script type="text/javascript" src="' . WP_PLUGIN_URL . '/google-routeplaner/google-routeplaner-js.php?planer_id=' . $planer['planer_id'] . ' "></script>';223 $map .= '<script type="text/javascript" src="' . WP_PLUGIN_URL . '/google-routeplaner/google-routeplaner-js.php?planer_id=' . $planer['planer_id'] . '&autofill=' . $planer['planer_autofill'] . '"></script>'; 215 224 216 225 if('personal_link' == get_option("google_routeplaner_donate") || 'commercial_link' == get_option("google_routeplaner_donate")) { … … 233 242 234 243 function google_routeplaner_admin_head() { 235 echo '<meta name="viewport" content="initial-scale=1.0, user-scalable= no" />244 echo '<meta name="viewport" content="initial-scale=1.0, user-scalable=yes" /> 236 245 <style type="text/css" media="screen"> 237 246 @import url("' . WP_PLUGIN_URL . '/google-routeplaner/google-routeplaner.css"); … … 241 250 242 251 function google_routeplaner_head() { 243 echo '<meta name="viewport" content="initial-scale=1.0, user-scalable= no" />';252 echo '<meta name="viewport" content="initial-scale=1.0, user-scalable=yes" />'; 244 253 } 245 254 add_action('wp_head', 'google_routeplaner_head'); -
google-routeplaner/trunk/readme.txt
r604907 r643415 1 === Google Routeplan er ===1 === Google Routeplanner === 2 2 Contributors: DerWebschmied 3 3 Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=VAFAKGCDQ2GHU 4 Tags: route, google, map, route planner, planer, route4 Tags: route, google, map, route planner, planer, planner, route 5 5 Requires at least: 3.0 6 6 Tested up to: 3.4.2 7 Stable tag: 2.3 7 Stable tag: 2.5 8 License: Feel free to edit for personal use 8 9 9 10 Allows you to add one or more route planners based on Google Maps to help your users to find a specific place. … … 15 16 The view of the plan can be quickly and easily adapt to your needs and of course it is also possible to create more then one route planner, for example to find venues. The well-known interface of Google Maps your users find quickly a way around. With a simple input field the user can specify their own location and not only gets directions but also a map with the marked path. 16 17 17 * [Plugin Support](http://support.derwebschied.de/) 18 = Support = 18 19 19 Romanian Translation [Web Geek Science](http://webhostinggeeks.com/) 20 Please don't use the WordPress.org Forums if you need help with the plugin. 21 Use our [Plugin Support Page](http://support.derwebschied.de/) instead. 22 23 = Translations = 24 * Romanian Translation: [Web Geek Science](http://webhostinggeeks.com/) 25 * French Translation: Corentin Smith 26 * Slovak Translation [WebHostingGeeks.com] (http://webhostinggeeks.com/blog/) 20 27 21 28 == Installation == … … 46 53 == Changelog == 47 54 48 = 2.3 = 55 = 2.5 = 56 * French translation added, thanks to Corentin Smith 57 * Slovak Translation by [WebHostingGeeks.com] (http://webhostinggeeks.com/blog/) added 58 * You can now define map height and width in px, % or em 59 * New feature: HTML5 detection for users location to autofill the form 60 61 = 2.3 = 49 62 * WordPress Multisite support 50 63 * Added default values for zoom level to prevent errors
Note: See TracChangeset
for help on using the changeset viewer.