Changeset 236
- Timestamp:
- 06/15/2011 04:34:23 AM (11 months ago)
- Location:
- trunk
- Files:
-
- 5 edited
-
config-sample/config.php (modified) (3 diffs)
-
globals/classes/srtm.php (modified) (1 diff)
-
globals/common.php (modified) (1 diff)
-
index.php (modified) (1 diff)
-
install/schema.sql (modified) (16 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/config-sample/config.php
r179 r236 8 8 'password' => "yourpassword", 9 9 'database' => "yourdatabase", 10 'version' => yourversion//Ex. 4.0, 4.1, 510 'version' => 5.0 //Ex. 4.0, 4.1, 5 11 11 ), 12 12 … … 94 94 'api' => '2.128e', 95 95 'keys' => array( // Domains must be as in $_SERVER['SERVER_NAME'] variable 96 'server.example.org/path' => 'example_key'96 // 'server.example.org/path' => 'example_key' 97 97 ), 98 98 'bounds' => array( 99 'min_latitude' => MINLAT_GPS_COORDINATE,100 'min_longitude' => MINLON_GPS_COORDINATE,101 'max_latitude' => MAXLAT_GPS_COORDINATE,102 'max_longitude' => MAXLON_GPS_COORDINATE99 'min_latitude' => 35, // MINLAT_GPS_COORDINATE, 100 'min_longitude' => 17, // MINLON_GPS_COORDINATE, 101 'max_latitude' => 42, // MAXLAT_GPS_COORDINATE, 102 'max_longitude' => 27 // MAXLON_GPS_COORDINATE 103 103 ) 104 104 ), … … 107 107 'enabled' => FALSE 108 108 ) 109 110 109 ); 111 112 ?> -
trunk/globals/classes/srtm.php
r175 r236 20 20 */ 21 21 22 /** 23 * Class to handle SRTM Data 24 */ 22 25 class srtm { 23 26 24 27 var $data_path; 25 28 26 function srtm($data_path='') {29 function __construct($data_path='') { 27 30 $this->data_path = $data_path; 31 } 32 33 public static function get_filename($lat, $lon) { 34 if ($lat < 0) { 35 $lat_dir = 'S'; 36 $lat_adj = 1; 37 } else { 38 $lat_dir = 'N'; 39 $lat_adj = 0; 40 } 41 if ($lon < 0) { 42 $lon_dir = 'W'; 43 $lon_adj = 1; 44 } else { 45 $lon_dir = 'E'; 46 $lon_adj = 0; 47 } 48 49 return $lat_dir . sprintf("%02.0f", (integer)($lat+$lat_adj)).$lon_dir.sprintf("%03.0f", (integer)($lon+$lon_adj)).'.hgt'; 28 50 } 29 51 -
trunk/globals/common.php
r145 r236 19 19 * 20 20 */ 21 21 if (file_exists(ROOT_PATH."/install")) { 22 die("WiND error: Please delete \"install/\" folder if you have completed installation ..."); 23 } 22 24 if (!file_exists(ROOT_PATH."config/config.php")) { 23 25 die("WiND error: Please make config/config.php file ..."); -
trunk/index.php
r143 r236 33 33 34 34 ob_end_flush(); 35 36 ?> -
trunk/install/schema.sql
r164 r236 1 1 2 CREATE TABLE `areas` (2 CREATE TABLE IF NOT EXISTS `areas` ( 3 3 `id` int(10) unsigned NOT NULL auto_increment, 4 4 `region_id` int(10) unsigned NOT NULL default '0', … … 14 14 ) ENGINE=MyISAM DEFAULT CHARSET=utf8; 15 15 16 CREATE TABLE `dns_nameservers` (16 CREATE TABLE IF NOT EXISTS `dns_nameservers` ( 17 17 `id` int(10) unsigned NOT NULL auto_increment, 18 18 `date_in` datetime NOT NULL default '0000-00-00 00:00:00', … … 31 31 ) ENGINE=MyISAM DEFAULT CHARSET=utf8; 32 32 33 CREATE TABLE `dns_zones` (33 CREATE TABLE IF NOT EXISTS `dns_zones` ( 34 34 `id` int(10) unsigned NOT NULL auto_increment, 35 35 `date_in` datetime NOT NULL default '0000-00-00 00:00:00', … … 49 49 ) ENGINE=MyISAM DEFAULT CHARSET=utf8; 50 50 51 CREATE TABLE `dns_zones_nameservers` (51 CREATE TABLE IF NOT EXISTS `dns_zones_nameservers` ( 52 52 `id` int(10) unsigned NOT NULL auto_increment, 53 53 `zone_id` int(10) unsigned NOT NULL default '0', … … 58 58 ) ENGINE=MyISAM DEFAULT CHARSET=utf8; 59 59 60 CREATE TABLE `ip_addresses` (60 CREATE TABLE IF NOT EXISTS `ip_addresses` ( 61 61 `id` int(10) unsigned NOT NULL auto_increment, 62 62 `date_in` datetime NOT NULL default '0000-00-00 00:00:00', … … 75 75 ) ENGINE=MyISAM DEFAULT CHARSET=utf8; 76 76 77 CREATE TABLE `ip_ranges` (77 CREATE TABLE IF NOT EXISTS `ip_ranges` ( 78 78 `id` int(10) unsigned NOT NULL auto_increment, 79 79 `date_in` datetime NOT NULL default '0000-00-00 00:00:00', … … 93 93 ) ENGINE=MyISAM DEFAULT CHARSET=utf8; 94 94 95 CREATE TABLE `links` (95 CREATE TABLE IF NOT EXISTS `links` ( 96 96 `id` int(10) unsigned NOT NULL auto_increment, 97 97 `date_in` datetime NOT NULL default '0000-00-00 00:00:00', … … 114 114 ) ENGINE=MyISAM DEFAULT CHARSET=utf8; 115 115 116 CREATE TABLE `nodes` (116 CREATE TABLE IF NOT EXISTS `nodes` ( 117 117 `id` int(10) unsigned NOT NULL auto_increment, 118 118 `date_in` datetime NOT NULL default '0000-00-00 00:00:00', … … 133 133 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 PACK_KEYS=0; 134 134 135 CREATE TABLE `nodes_services` (135 CREATE TABLE IF NOT EXISTS `nodes_services` ( 136 136 `id` int(10) unsigned NOT NULL auto_increment, 137 137 `date_in` datetime NOT NULL default '0000-00-00 00:00:00', … … 150 150 ) ENGINE=MyISAM DEFAULT CHARSET=utf8; 151 151 152 CREATE TABLE `photos` (152 CREATE TABLE IF NOT EXISTS `photos` ( 153 153 `id` int(10) unsigned NOT NULL auto_increment, 154 154 `date_in` datetime NOT NULL default '0000-00-00 00:00:00', … … 164 164 ) ENGINE=MyISAM DEFAULT CHARSET=utf8; 165 165 166 CREATE TABLE `regions` (166 CREATE TABLE IF NOT EXISTS `regions` ( 167 167 `id` int(10) unsigned NOT NULL auto_increment, 168 168 `name` varchar(40) NOT NULL default '', … … 176 176 ) ENGINE=MyISAM DEFAULT CHARSET=utf8; 177 177 178 CREATE TABLE `rights` (178 CREATE TABLE IF NOT EXISTS `rights` ( 179 179 `id` int(10) unsigned NOT NULL auto_increment, 180 180 `user_id` int(10) unsigned NOT NULL default '0', … … 185 185 ) ENGINE=MyISAM DEFAULT CHARSET=utf8; 186 186 187 CREATE TABLE `services` (187 CREATE TABLE IF NOT EXISTS `services` ( 188 188 `id` int(10) unsigned NOT NULL auto_increment, 189 189 `title` varchar(255) NOT NULL default '', … … 194 194 ) ENGINE=MyISAM DEFAULT CHARSET=utf8; 195 195 196 CREATE TABLE `subnets` (196 CREATE TABLE IF NOT EXISTS `subnets` ( 197 197 `id` int(10) unsigned NOT NULL auto_increment, 198 198 `date_in` datetime NOT NULL default '0000-00-00 00:00:00', … … 207 207 ) ENGINE=MyISAM DEFAULT CHARSET=utf8; 208 208 209 CREATE TABLE `users` (209 CREATE TABLE IF NOT EXISTS `users` ( 210 210 `id` int(10) unsigned NOT NULL auto_increment, 211 211 `date_in` datetime NOT NULL default '0000-00-00 00:00:00', … … 232 232 ) ENGINE=MyISAM DEFAULT CHARSET=utf8; 233 233 234 CREATE TABLE `users_nodes` (234 CREATE TABLE IF NOT EXISTS `users_nodes` ( 235 235 `id` int(10) unsigned NOT NULL auto_increment, 236 236 `user_id` int(10) unsigned NOT NULL default '0',
Note: See TracChangeset
for help on using the changeset viewer.
