Changeset 242
- Timestamp:
- 06/16/2011 01:30:41 AM (11 months ago)
- Location:
- trunk
- Files:
-
- 10 edited
-
. (modified) (1 prop)
-
globals/functions.php (modified) (2 diffs)
-
globals/language/english.php (modified) (2 diffs)
-
globals/language/greek.php (modified) (3 diffs)
-
includes/pages/dnszones/dnszones.php (modified) (2 diffs)
-
includes/pages/hostmaster/hostmaster_dnszones.php (modified) (2 diffs)
-
includes/pages/hostmaster/hostmaster_ranges.php (modified) (2 diffs)
-
includes/pages/mynodes/mynodes_dnszone.php (modified) (2 diffs)
-
includes/pages/ranges/ranges_search.php (modified) (2 diffs)
-
install/schema.sql (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk
-
Property
svn:mergeinfo
set to
/branches/awmn merged eligible
-
Property
svn:mergeinfo
set to
-
trunk/globals/functions.php
r190 r242 4 4 * 5 5 * Copyright (C) 2005 Nikolaos Nikalexis <winner@cube.gr> 6 * Copyright (C) 2009 Vasilis Tsiligiannis <b_tsiligiannis@silverton.gr> 6 7 * 7 8 * This program is free software; you can redistribute it and/or modify … … 312 313 } 313 314 315 function validate_zone($name) { 316 $name = str_replace("_", "-", $name); 317 $name = strtolower($name); 318 if (preg_match('/^((([[:alnum:]]|[[:alnum:]][[:alnum:]-]*[[:alnum:]])\.)*([[:alnum:]]|[[:alnum:]][[:alnum:]-]*[[:alnum:]])|)$/', $name) == 0) return NULL; 319 return $name; 320 } 321 314 322 function validate_name_ns($name, $node) { 315 323 global $db; -
trunk/globals/language/english.php
r168 r242 4 4 * 5 5 * Copyright (C) 2005 Nikolaos Nikalexis <winner@cube.gr> 6 * Copyright (C) 2009 Vasilis Tsiligiannis <b_tsiligiannis@silverton.gr> 6 7 * 7 8 * This program is free software; you can redistribute it and/or modify … … 495 496 'body' => 'The node you are looking for does not exist. Check that you supplied the correct data and try again. If you are sure that you submit the correct data, it is likely that the node has been deleted or that the user has not activated his/her account yet.' 496 497 ), 498 'zone_invalid_name' => array( 499 'title' => 'Invalid zone name', 500 'body' => 'The name of the zone contains invalid characters.' 501 ), 502 'zone_out_of_range' => array( 503 'title' => 'Zone name not in C-Class', 504 'body' => 'The name of the zone does not match to any of the IP C-Classes that have been assigned to your node.' 505 ), 506 'zone_reserved_name' => array( 507 'title' => 'Reserved zone name', 508 'body' => 'The name of the zone is reserved by the system.' 509 ), 497 510 'generic' => array( 498 511 'title' => "General error", -
trunk/globals/language/greek.php
r159 r242 4 4 * 5 5 * Copyright (C) 2005 Nikolaos Nikalexis <winner@cube.gr> 6 * Copyright (C) 2009 Vasilis Tsiligiannis <b_tsiligiannis@silverton.gr> 6 7 * 7 8 * This program is free software; you can redistribute it and/or modify … … 20 21 */ 21 22 22 /* el_GR for GNU/Linux - ell for Windows */23 /* el_GR.utf8 for GNU/Linux - ell for Windows */ 23 24 setlocale(LC_ALL, 'el_GR', 'ell'); 24 25 … … 685 686 λογαÏιαÏΌοÏ.' 686 687 ), 688 'zone_invalid_name' => array( 689 'title' => 'Îη ÎÎ³ÎºÏ 690 Ïο ÏΜοΌα ζÏΜηÏ', 691 'body' => '΀ο ÏΜοΌα ζÏÎœÎ·Ï ÏÎ¿Ï 692 ΎηλÏÏαÏε ÏεÏιÎÏει Όη ÎÎ³ÎºÏ 693 ÏÎ¿Ï 694 Ï ÏαÏακÏήÏεÏ.' 695 ), 696 'zone_out_of_range' => array( 697 'title' => 'ÎΜοΌα ζÏÎœÎ·Ï ÎµÎºÏÏÏ C-Class', 698 'body' => '΀ο ÏΜοΌα ζÏÎœÎ·Ï ÏÎ¿Ï 699 ΎηλÏÏαÏε ΎεΜ αΜÏιÏÏοιÏεί Ïε καΜÎΜα αÏÏ Ïα C-Classes ÏÎ¿Ï 700 ÏÎ±Ï ÎÏÎ¿Ï 701 Μ αÏοΎοΞεί.' 702 ), 703 'zone_reserved_name' => array( 704 'title' => 'ÎεÏÎŒÎµÏ 705 ÎŒÎΜο ÏΜοΌα ζÏΜηÏ', 706 'body' => '΀ο ÏΜοΌα ζÏÎœÎ·Ï ÏÎ¿Ï 707 ΎηλÏÏαÏε είΜαι ΎεÏÎŒÎµÏ 708 ÎŒÎΜο αÏÏ Ïο ÏÏÏÏηΌα.' 709 ), 687 710 'generic' => array( 688 711 'title' => "ÎÎµÎœÎ¹ÎºÏ ÏÏάλΌα", -
trunk/includes/pages/dnszones/dnszones.php
r71 r242 4 4 * 5 5 * Copyright (C) 2005 Nikolaos Nikalexis <winner@cube.gr> 6 * Copyright (C) 2009 Vasilis Tsiligiannis <b_tsiligiannis@silverton.gr> 6 7 * 7 8 * This program is free software; you can redistribute it and/or modify … … 51 52 "", 52 53 "dns_zones.status ASC, dns_zones.type ASC, dns_zones.name ASC"); 54 $table_dns->db_data_search($form_search_dns); 53 55 for($i=1;$i<count($table_dns->data);$i++) { 54 56 if (isset($table_dns->data[$i])) { -
trunk/includes/pages/hostmaster/hostmaster_dnszones.php
r26 r242 4 4 * 5 5 * Copyright (C) 2005 Nikolaos Nikalexis <winner@cube.gr> 6 * Copyright (C) 2009 Vasilis Tsiligiannis <b_tsiligiannis@silverton.gr> 6 7 * 7 8 * This program is free software; you can redistribute it and/or modify … … 48 49 "", 49 50 "dns_zones.date_in DESC, dns_zones.status ASC"); 51 $table_dns->db_data_search($form_search_dns); 50 52 $table_dns->db_data_multichoice('dns_zones', 'id'); 51 53 for($i=1;$i<count($table_dns->data);$i++) { -
trunk/includes/pages/hostmaster/hostmaster_ranges.php
r26 r242 4 4 * 5 5 * Copyright (C) 2005 Nikolaos Nikalexis <winner@cube.gr> 6 * Copyright (C) 2009 Vasilis Tsiligiannis <b_tsiligiannis@silverton.gr> 6 7 * 7 8 * This program is free software; you can redistribute it and/or modify … … 53 54 "", 54 55 "ip_ranges.date_in DESC, ip_ranges.status ASC"); 56 $table_ip_ranges->db_data_search($form_search_ranges); 55 57 foreach( (array) $table_ip_ranges->data as $key => $value) { 56 58 if ($key != 0) { -
trunk/includes/pages/mynodes/mynodes_dnszone.php
r149 r242 4 4 * 5 5 * Copyright (C) 2005 Nikolaos Nikalexis <winner@cube.gr> 6 * Copyright (C) 2009 Vasilis Tsiligiannis <b_tsiligiannis@silverton.gr> 6 7 * 7 8 * This program is free software; you can redistribute it and/or modify … … 77 78 $_POST['dns_zones__name'] = substr($_POST['dns_zones__name'], 0, -strlen($vars['dns']['root_zone'])-1); 78 79 } 80 $_POST['dns_zones__name'] = validate_zone($_POST['dns_zones__name']); 79 81 $form_zone = $this->form_zone(); 80 82 $ret = TRUE; 81 83 $f = array(); 82 84 if (get('zone') == 'add') { 85 if ($_POST['dns_zones__name'] == '') { 86 if (is_null($_POST['dns_zones__name'])) $main->message->set_fromlang('error', 'zone_invalid_name'); 87 else $db->output_error_fields_required(array('dns_zones__name')); 88 return; 89 } 90 switch (get('type')) { 91 case 'forward': 92 if ($_POST['dns_zones__name'].'.'.$vars['dns']['root_zone'] == $vars['dns']['ns_zone']) { 93 $main->message->set_fromlang('error', 'zone_reserved_name'); 94 return; 95 } 96 break; 97 case 'reverse': 98 $iprange = $db->get("ip_start, ip_end", 99 "ip_ranges", 100 "node_id = ".intval(get('node'))); 101 foreach( (array) $iprange as $value) 102 if (reverse_zone_from_ip(long2ip($value['ip_start'])) == $_POST['dns_zones__name']) { 103 $valid = TRUE; 104 break; 105 } 106 if (!$valid) { 107 $main->message->set_fromlang('error', 'zone_out_of_range'); 108 return; 109 } 110 break; 111 default: 112 $main->message->set_fromlang('error', 'generic'); 113 return; 114 } 83 115 $f = array('dns_zones.status' => 'waiting', 'dns_zones.type' => get('type'), "dns_zones.node_id" => intval(get('node'))); 84 116 $ret = $form_zone->db_set($f, -
trunk/includes/pages/ranges/ranges_search.php
r154 r242 4 4 * 5 5 * Copyright (C) 2005 Nikolaos Nikalexis <winner@cube.gr> 6 * Copyright (C) 2009 Vasilis Tsiligiannis <b_tsiligiannis@silverton.gr> 6 7 * 7 8 * This program is free software; you can redistribute it and/or modify … … 57 58 "", 58 59 "ip_ranges.status ASC, ip_ranges.ip_start ASC"); 60 $table_ip_ranges->db_data_search($form_search_ranges); 59 61 foreach( (array) $table_ip_ranges->data as $key => $value) { 60 62 if ($key != 0) { -
trunk/install/schema.sql
r236 r242 101 101 `type` enum('p2p','ap','client') NOT NULL default 'p2p', 102 102 `ssid` varchar(50) default NULL, 103 `protocol` enum('IEEE 802.11b','IEEE 802.11g','IEEE 802.11a',' other') default NULL,103 `protocol` enum('IEEE 802.11b','IEEE 802.11g','IEEE 802.11a','IEEE 802.11n','IEEE 802.3i (Ethernet)','IEEE 802.3u (Fast Ethernet)','IEEE 802.3ab (Gigabit Ethernet)','other') default NULL, 104 104 `channel` varchar(50) default NULL, 105 105 `status` enum('active','inactive') NOT NULL default 'active',
Note: See TracChangeset
for help on using the changeset viewer.
