Project

General

Profile

« Previous | Next » 

Revision f2fe3984

Added by Scott Ullrich almost 16 years ago

Break each interface up into their own listoptics

View differences:

usr/local/www/wizards/traffic_shaper_wizard.inc
33 33

  
34 34
function step1_submitphpaction() {
35 35

  
36
		if (!isset($_POST['numberofconnections'])) {
36
		if (!isset($_POST['enternumberofwanconnections'])) {
37 37
			$message=gettext("You need to specify the number of connections.");
38 38
			header("Location:wizard.php?xml=traffic_shaper_wizard.xml&stepid=0&message={$message}");
39 39
			exit;
40 40
		}			
41
		if (intval($_POST['numberofconnections']) > 100 || intval($_POST['numberofconnections']) < 1) {
41
		if (intval($_POST['enternumberofwanconnections']) > 100 || intval($_POST['enternumberofwanconnections']) < 1) {
42 42
			$message=gettext("The number of connections supported is between 1 and 100.");
43 43
			header("Location:wizard.php?xml=traffic_shaper_wizard.xml&stepid=0&message={$message}");
44 44
			exit;
......
101 101
		$field['options']['option'][] = $opts;
102 102
		$field['bindstofield'] = "ezshaper->step2->downloadscheduler";
103 103
		$fields[] = $field;
104
		$field = array();
105
		$field['name'] = "Setup connections speeds";
106
		$field['type'] = "listtopic";
107
		$fields[] = $field;
104

  
108 105

  
109 106
		for ($i = 0; $i < $numberofconnections; $i++) {
107

  
108
			$field = array();
109
			$interface_friendly = $i+1;
110
			$field['name'] = "Setup connection speed and scheduler information for interface #{$interface_friendly}";
111
			$field['type'] = "listtopic";
112
			$fields[] = $field;
113
			
110 114
			$field = array();
111 115
			$field['displayname'] = "Interface";
112 116
			$field['name'] = "conn{$i}interface";
113 117
			$field['type'] = "select";
114
			$field['typehint'] = "Interface of this connection.";
118
			$field['typehint'] = "Interface of connection #{$interface_friendly}.";
115 119
			$field['options']['option'] = array();
116 120
			foreach ($iflist as $ifname => $ifdescr) {
117 121
				$opts = array();

Also available in: Unified diff