Completed
Pull Request — master (#532)
06:37
created
app/install/select_install_type.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@  discard block
 block discarded – undo
17 17
 		<ol style="margin-top:20px;">
18 18
 		<!-- automatic -->
19 19
 		<li>
20
-			<a href="<?php print create_link("install","install_automatic",null,null,null,true); ?>" class="btn btn-sm btn-default">Automatic database installation</a>
20
+			<a href="<?php print create_link ("install", "install_automatic", null, null, null, true); ?>" class="btn btn-sm btn-default">Automatic database installation</a>
21 21
 			<br>
22 22
 			<div class="text-muted">phpipam installer will create database for you automatically.</div>
23 23
 			<br>
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
 		
26 26
 		<!-- Mysql inport -->
27 27
 		<li>
28
-			<a href="<?php print create_link("install","install_mysqlimport",null,null,null,true); ?>" class="btn btn-sm btn-default">MySQL import instructions</a>	
28
+			<a href="<?php print create_link ("install", "install_mysqlimport", null, null, null, true); ?>" class="btn btn-sm btn-default">MySQL import instructions</a>	
29 29
 			<br>
30 30
 			<div class="text-muted">Install DB files with mysqlimport tool.</div>
31 31
 			<br>		
@@ -33,7 +33,7 @@  discard block
 block discarded – undo
33 33
 		
34 34
 		<!-- Manual install -->
35 35
 		<li>
36
-			<a href="<?php print create_link("install","install_manual",null,null,null,true); ?>" class="btn btn-sm btn-default">Manual database installation</a>	
36
+			<a href="<?php print create_link ("install", "install_manual", null, null, null, true); ?>" class="btn btn-sm btn-default">Manual database installation</a>	
37 37
 			<br>
38 38
 			<div class="text-muted">Install database manually with SQL queries.</div>
39 39
 			<br>		
Please login to merge, or discard this patch.
app/admin/ripe-import/index.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -5,21 +5,21 @@
 block discarded – undo
5 5
  *************************************************/
6 6
 
7 7
 # verify that user is logged in
8
-$User->check_user_session();
8
+$User->check_user_session ();
9 9
 ?>
10 10
 
11
-<h4><?php print _('Import subnets from RIPE'); ?></h4>
11
+<h4><?php print _ ('Import subnets from RIPE'); ?></h4>
12 12
 <hr><br>
13 13
 
14 14
 
15
-<?php $Result->show("info alert-absolute",  _('This script imports subnets from RIPE database for specific AS. Enter desired AS to search for subnets'), false); ?>
15
+<?php $Result->show ("info alert-absolute", _ ('This script imports subnets from RIPE database for specific AS. Enter desired AS to search for subnets'), false); ?>
16 16
 
17 17
 <form name="ripeImport" id="ripeImport" style="margin-top:50px;clear:both;" class="form-inline" role="form">
18 18
 	<div class="form-group">
19
-		<input class="search form-control input-sm" placeholder="<?php print _('AS number'); ?>" name="as" type="text">
19
+		<input class="search form-control input-sm" placeholder="<?php print _ ('AS number'); ?>" name="as" type="text">
20 20
 	</div>
21 21
 	<div class="form-group">
22
-		<button type="submit" class="btn btn-sm btn-default"><?php print _('Search'); ?></button>
22
+		<button type="submit" class="btn btn-sm btn-default"><?php print _ ('Search'); ?></button>
23 23
 	</div>
24 24
 </form>
25 25
 
Please login to merge, or discard this patch.
app/admin/powerDNS/refresh-ptr-records.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -1,9 +1,9 @@  discard block
 block discarded – undo
1 1
 <!-- header -->
2
-<div class="pHeader"><?php print _("PTR zone refresh records"); ?></div>
2
+<div class="pHeader"><?php print _ ("PTR zone refresh records"); ?></div>
3 3
 
4 4
 <!-- content -->
5 5
 <div class="pContent">
6
-	<?php print _('Clicking on regenerate will remove all PTR records for subnet and recreate new.'); ?>
6
+	<?php print _ ('Clicking on regenerate will remove all PTR records for subnet and recreate new.'); ?>
7 7
 	<br>
8 8
 
9 9
 	<div class="text-righ2t">
@@ -19,6 +19,6 @@  discard block
 block discarded – undo
19 19
 <!-- footer -->
20 20
 <div class="pFooter">
21 21
 	<div class="btn-group">
22
-		<button class="btn btn-sm btn-default hidePopupsReload"><?php print _('Close'); ?></button>
22
+		<button class="btn btn-sm btn-default hidePopupsReload"><?php print _ ('Close'); ?></button>
23 23
 	</div>
24 24
 </div>
25 25
\ No newline at end of file
Please login to merge, or discard this patch.
app/admin/api/generate-key.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,3 +1,3 @@
 block discarded – undo
1 1
 <?php
2
-print str_shuffle(md5(microtime()));
2
+print str_shuffle (md5 (microtime ()));
3 3
 ?>
4 4
\ No newline at end of file
Please login to merge, or discard this patch.
app/admin/mail/index.php 1 patch
Spacing   +34 added lines, -34 removed lines patch added patch discarded remove patch
@@ -5,17 +5,17 @@  discard block
 block discarded – undo
5 5
  **************************/
6 6
 
7 7
 # verify that user is logged in
8
-$User->check_user_session();
8
+$User->check_user_session ();
9 9
 
10 10
 # fetch mail settings
11
-$mail_settings = $Admin->fetch_object("settingsMail", "id", 1);
11
+$mail_settings = $Admin->fetch_object ("settingsMail", "id", 1);
12 12
 
13 13
 # create csrf token
14 14
 $csrf = $User->create_csrf_cookie ();
15 15
 ?>
16 16
 
17 17
 <!-- title -->
18
-<h4>phpIPAM <?php print _('Mail settings'); ?></h4>
18
+<h4>phpIPAM <?php print _ ('Mail settings'); ?></h4>
19 19
 <hr>
20 20
 
21 21
 <form name="mailsettings" id="mailsettings">
@@ -23,88 +23,88 @@  discard block
 block discarded – undo
23 23
 
24 24
 	<!-- Server settings -->
25 25
 	<tr class="settings-title">
26
-		<th colspan="3"><h4><?php print _('Mail server type'); ?></h4></th>
26
+		<th colspan="3"><h4><?php print _ ('Mail server type'); ?></h4></th>
27 27
 	</tr>
28 28
 
29 29
 	<!-- Server type -->
30 30
 	<tr>
31
-		<td><?php print _('Server type'); ?></th>
31
+		<td><?php print _ ('Server type'); ?></th>
32 32
 		<td>
33 33
 			<select name="mtype" class="form-control input-sm input-w-auto" id="mtype">
34
-				<option value="localhost"><?php print _("Localhost"); ?></option>
35
-				<option value="smtp" <?php if($mail_settings->mtype=="smtp") print "selected='selected'"; ?>><?php print _("SMTP"); ?></option>
34
+				<option value="localhost"><?php print _ ("Localhost"); ?></option>
35
+				<option value="smtp" <?php if ($mail_settings->mtype == "smtp") print "selected='selected'"; ?>><?php print _ ("SMTP"); ?></option>
36 36
 			</select>
37 37
 			<input type="hidden" name="csrf_cookie" value="<?php print $csrf; ?>">
38 38
 		</td>
39
-		<td class="info2"><?php print _('Select server type for sending mail messages'); ?></td>
39
+		<td class="info2"><?php print _ ('Select server type for sending mail messages'); ?></td>
40 40
 	</tr>
41 41
 
42 42
 	<!-- smtp -->
43
-	<tbody id="smtp" <?php if($mail_settings->mtype=="localhost") print "style='display:none;'"; ?>>
43
+	<tbody id="smtp" <?php if ($mail_settings->mtype == "localhost") print "style='display:none;'"; ?>>
44 44
 
45 45
 	<!-- Server settings -->
46 46
 	<tr class="settings-title">
47
-		<th colspan="3"><h4><?php print _('SMTP settings'); ?></h4></th>
47
+		<th colspan="3"><h4><?php print _ ('SMTP settings'); ?></h4></th>
48 48
 	</tr>
49 49
 	<!-- Server -->
50 50
 	<tr>
51
-		<td><?php print _('Server address'); ?></th>
51
+		<td><?php print _ ('Server address'); ?></th>
52 52
 		<td>
53 53
 			<input type="text" name="mserver" class='smtp form-control input-sm' value="<?php print $mail_settings->mserver; ?>">
54 54
 		</td>
55
-		<td class="info2"><?php print _('Set SMTP server address'); ?></td>
55
+		<td class="info2"><?php print _ ('Set SMTP server address'); ?></td>
56 56
 	</tr>
57 57
 
58 58
 	<!-- Port -->
59 59
 	<tr>
60
-		<td><?php print _('Port'); ?></th>
60
+		<td><?php print _ ('Port'); ?></th>
61 61
 		<td>
62 62
 			<input type="text" name="mport" class='smtp form-control input-sm' value="<?php print $mail_settings->mport; ?>">
63 63
 		</td>
64
-		<td class="info2"><?php print _('Set SMTP server port'); ?> (25, 465 or 587)</td>
64
+		<td class="info2"><?php print _ ('Set SMTP server port'); ?> (25, 465 or 587)</td>
65 65
 	</tr>
66 66
 
67 67
 	<!-- tls -->
68 68
 	<tr>
69
-		<td><?php print _('Security'); ?></th>
69
+		<td><?php print _ ('Security'); ?></th>
70 70
 		<td>
71 71
 			<select name="msecure" class="smtp form-control input-sm input-w-auto">
72
-				<option value="none"><?php print _('None'); ?></option>
73
-				<option value="ssl" <?php if($mail_settings->msecure=="ssl") print "selected='selected'"; ?>><?php print _('SSL'); ?></option>
74
-				<option value="tls" <?php if($mail_settings->msecure=="tls") print "selected='selected'"; ?>><?php print _('TLS'); ?></option>
72
+				<option value="none"><?php print _ ('None'); ?></option>
73
+				<option value="ssl" <?php if ($mail_settings->msecure == "ssl") print "selected='selected'"; ?>><?php print _ ('SSL'); ?></option>
74
+				<option value="tls" <?php if ($mail_settings->msecure == "tls") print "selected='selected'"; ?>><?php print _ ('TLS'); ?></option>
75 75
 			</select>
76 76
 		</td>
77
-		<td class="info2"><?php print _('Select yes if authentication is required'); ?></td>
77
+		<td class="info2"><?php print _ ('Select yes if authentication is required'); ?></td>
78 78
 	</tr>
79 79
 
80 80
 	<!-- Server auth -->
81 81
 	<tr>
82
-		<td><?php print _('Server authentication'); ?></th>
82
+		<td><?php print _ ('Server authentication'); ?></th>
83 83
 		<td>
84 84
 			<select name="mauth" class="smtp form-control input-sm input-w-auto">
85
-				<option value="no"><?php print _('No'); ?></option>
86
-				<option value="yes" <?php if($mail_settings->mauth=="yes") print "selected='selected'"; ?>><?php print _('Yes'); ?></option>
85
+				<option value="no"><?php print _ ('No'); ?></option>
86
+				<option value="yes" <?php if ($mail_settings->mauth == "yes") print "selected='selected'"; ?>><?php print _ ('Yes'); ?></option>
87 87
 			</select>
88 88
 		</td>
89
-		<td class="info2"><?php print _('Select yes if authentication is required'); ?></td>
89
+		<td class="info2"><?php print _ ('Select yes if authentication is required'); ?></td>
90 90
 	</tr>
91 91
 
92 92
 	<!-- Username -->
93 93
 	<tr>
94
-		<td><?php print _('Username'); ?></th>
94
+		<td><?php print _ ('Username'); ?></th>
95 95
 		<td>
96 96
 			<input type="text" name="muser" class='smtp form-control input-sm' value="<?php print $mail_settings->muser; ?>">
97 97
 		</td>
98
-		<td class="info2"><?php print _('Set username for SMTP authentication'); ?></td>
98
+		<td class="info2"><?php print _ ('Set username for SMTP authentication'); ?></td>
99 99
 	</tr>
100 100
 
101 101
 	<!-- Password -->
102 102
 	<tr>
103
-		<td><?php print _('Password'); ?></th>
103
+		<td><?php print _ ('Password'); ?></th>
104 104
 		<td>
105 105
 			<input type="password" name="mpass" class='smtp form-control input-sm' value="<?php print $mail_settings->mpass; ?>">
106 106
 		</td>
107
-		<td class="info2"><?php print _('Set password for SMTP authentication'); ?></td>
107
+		<td class="info2"><?php print _ ('Set password for SMTP authentication'); ?></td>
108 108
 	</tr>
109 109
 
110 110
 	</tbody>
@@ -113,28 +113,28 @@  discard block
 block discarded – undo
113 113
 
114 114
 	<!-- Sender settings -->
115 115
 	<tr class="settings-title">
116
-		<th colspan="3"><h4><?php print _('Mail sender settings'); ?></h4></th>
116
+		<th colspan="3"><h4><?php print _ ('Mail sender settings'); ?></h4></th>
117 117
 	</tr>
118 118
 
119 119
 	<!-- Admin name -->
120 120
 	<tr>
121
-		<td class="title"><?php print _('Sender name'); ?></td>
121
+		<td class="title"><?php print _ ('Sender name'); ?></td>
122 122
 		<td>
123 123
 			<input type="text" size="50" class="form-control input-sm" name="mAdminName" value="<?php print $mail_settings->mAdminName; ?>">
124 124
 		</td>
125 125
 		<td class="info2">
126
-			<?php print _('Set administrator name to display when sending mails and for contact info'); ?>
126
+			<?php print _ ('Set administrator name to display when sending mails and for contact info'); ?>
127 127
 		</td>
128 128
 	</tr>
129 129
 
130 130
 	<!-- Admin mail -->
131 131
 	<tr>
132
-		<td class="title"><?php print _('Admin mail'); ?></td>
132
+		<td class="title"><?php print _ ('Admin mail'); ?></td>
133 133
 		<td>
134 134
 			<input type="text" size="50" class="form-control input-sm" name="mAdminMail" value="<?php print $mail_settings->mAdminMail; ?>">
135 135
 		</td>
136 136
 		<td class="info2">
137
-			<?php print _('Set administrator e-mail to display when sending mails and for contact info'); ?>
137
+			<?php print _ ('Set administrator e-mail to display when sending mails and for contact info'); ?>
138 138
 		</td>
139 139
 	</tr>
140 140
 
@@ -144,8 +144,8 @@  discard block
 block discarded – undo
144 144
 		<td class="title"></td>
145 145
 		<td class="submit" style="padding-top:30px;">
146 146
 		<div class="btn-group pull-right">
147
-			<a class="btn btn-sm btn-default sendTestMail"><i class="icon icon-gray icon-envelope"></i> <?php print _('Send test email'); ?></a>
148
-			<input type="submit" class="btn btn-sm btn-default btn-success pull-right" value="<?php print _('Save changes'); ?>">
147
+			<a class="btn btn-sm btn-default sendTestMail"><i class="icon icon-gray icon-envelope"></i> <?php print _ ('Send test email'); ?></a>
148
+			<input type="submit" class="btn btn-sm btn-default btn-success pull-right" value="<?php print _ ('Save changes'); ?>">
149 149
 		</div>
150 150
 		</td>
151 151
 		<td></td>
Please login to merge, or discard this patch.
app/admin/import-export/import-constants.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -3,12 +3,12 @@
 block discarded – undo
3 3
 // Data Import Constants
4 4
 
5 5
 # display icons and colors for actions
6
-$icons = array();
6
+$icons = array ();
7 7
 $icons['add'] = "fa-plus";
8 8
 $icons['edit'] = "fa-pencil";
9 9
 $icons['skip'] = "fa-times";
10 10
 $icons['error'] = "fa-times";
11
-$colors = array();
11
+$colors = array ();
12 12
 $colors['add'] = "success";
13 13
 $colors['edit'] = "info";
14 14
 $colors['skip'] = "warning";
Please login to merge, or discard this patch.
app/admin/import-export/index.php 1 patch
Spacing   +24 added lines, -24 removed lines patch added patch discarded remove patch
@@ -5,7 +5,7 @@  discard block
 block discarded – undo
5 5
  *************************************************/
6 6
 
7 7
 # verify that user is logged in
8
-$User->check_user_session();
8
+$User->check_user_session ();
9 9
 ?>
10 10
 
11 11
 <script type="text/javascript">
@@ -20,37 +20,37 @@  discard block
 block discarded – undo
20 20
 
21 21
 </script>
22 22
 
23
-<h4><?php print _('Import / Export'); ?></h4>
23
+<h4><?php print _ ('Import / Export'); ?></h4>
24 24
 <hr><br>
25 25
 
26 26
 <form name="dataImportExport" id="dataImportExport">
27 27
 <table id="dataImportExport" class="table table-hover table-condensed table-top table-auto">
28 28
 	<tr>
29
-		<th colspan="3"><h4><?php print _('Pick a data set type, and click on an action'); ?></h4></th>
29
+		<th colspan="3"><h4><?php print _ ('Pick a data set type, and click on an action'); ?></h4></th>
30 30
 	</tr>
31 31
 	<tr>
32
-		<td class="title"><?php print _('Data set'); ?></td>
32
+		<td class="title"><?php print _ ('Data set'); ?></td>
33 33
 		<td>
34
-			<select name="dataType" id="dataType" class="form-control input-sm input-w-auto" rel='tooltip' data-placement='right' title='<?php print _('Pick data set'); ?>'>
35
-					<option value='vrf'><?php print _('VRF'); ?></option>
36
-					<option value='vlan'><?php print _('VLAN'); ?></option>
37
-					<option value='l2dom'><?php print _('L2 Domains'); ?></option>
38
-					<option value='subnets'><?php print _('Subnets'); ?></option>
39
-					<option value='ipaddr'><?php print _('IP addresses'); ?></option>
40
-					<option value='devices' disabled><?php print _('Devices'); ?></option>
41
-					<option value='devtype' disabled><?php print _('Device types'); ?></option>
34
+			<select name="dataType" id="dataType" class="form-control input-sm input-w-auto" rel='tooltip' data-placement='right' title='<?php print _ ('Pick data set'); ?>'>
35
+					<option value='vrf'><?php print _ ('VRF'); ?></option>
36
+					<option value='vlan'><?php print _ ('VLAN'); ?></option>
37
+					<option value='l2dom'><?php print _ ('L2 Domains'); ?></option>
38
+					<option value='subnets'><?php print _ ('Subnets'); ?></option>
39
+					<option value='ipaddr'><?php print _ ('IP addresses'); ?></option>
40
+					<option value='devices' disabled><?php print _ ('Devices'); ?></option>
41
+					<option value='devtype' disabled><?php print _ ('Device types'); ?></option>
42 42
 			</select>
43 43
 		</td>
44
-		<td class="info2"><?php print _('Not all options are available currently.'); ?></td>
44
+		<td class="info2"><?php print _ ('Not all options are available currently.'); ?></td>
45 45
 	</tr>
46 46
 	<tr>
47 47
 		<td>Action</td>
48 48
 		<td colspan="2">
49 49
 			<div class="btn-group">
50
-				<button class='dataImport btn btn-sm btn-default' rel='tooltip' data-placement='bottom' title='<?php print _('Import data entries for the selected type'); ?>'><i class='fa fa-download'></i> <?php print _('Import'); ?></button>
51
-				<button class='dataExport btn btn-sm btn-default' rel='tooltip' data-placement='bottom' title='<?php print _('Export data entries for the selected type'); ?>'><i class='fa fa-upload'></i> <?php print _('Export'); ?></button>
50
+				<button class='dataImport btn btn-sm btn-default' rel='tooltip' data-placement='bottom' title='<?php print _ ('Import data entries for the selected type'); ?>'><i class='fa fa-download'></i> <?php print _ ('Import'); ?></button>
51
+				<button class='dataExport btn btn-sm btn-default' rel='tooltip' data-placement='bottom' title='<?php print _ ('Export data entries for the selected type'); ?>'><i class='fa fa-upload'></i> <?php print _ ('Export'); ?></button>
52 52
 			</div>
53
-			<button class="dataRecompute btn btn-sm btn-default" id="dataRecompute" style="display: none;" rel='tooltip' data-placement='bottom' title='<?php print _('Recompute master/nested subnet relations.'); ?>'><i class="fa fa-magic"></i> <?php print _('Recompute'); ?></button>
53
+			<button class="dataRecompute btn btn-sm btn-default" id="dataRecompute" style="display: none;" rel='tooltip' data-placement='bottom' title='<?php print _ ('Recompute master/nested subnet relations.'); ?>'><i class="fa fa-magic"></i> <?php print _ ('Recompute'); ?></button>
54 54
 		</td>
55 55
 	</tr>
56 56
 </table>
@@ -58,20 +58,20 @@  discard block
 block discarded – undo
58 58
 
59 59
 
60 60
 
61
-<h4 style="margin-top:100px;"><?php print _('phpIPAM database export'); ?></h4>
61
+<h4 style="margin-top:100px;"><?php print _ ('phpIPAM database export'); ?></h4>
62 62
 <hr><br>
63 63
 
64
-<div class="alert alert-info alert-absolute"><?php print _('You can download MySQL dump of database or generate XLS file of IP addresses'); ?>!</div>
64
+<div class="alert alert-info alert-absolute"><?php print _ ('You can download MySQL dump of database or generate XLS file of IP addresses'); ?>!</div>
65 65
 
66 66
 <!-- MySQL dump -->
67 67
 <hr style="margin-top:50px;">
68
-<h4><?php print _('Create MySQL database dump'); ?></h4>
69
-<button class="btn btn-sm btn-default" id="MySQLdump"><i class="fa fa-upload"></i> <?php print _('Prepare MySQL dump'); ?></button>
68
+<h4><?php print _ ('Create MySQL database dump'); ?></h4>
69
+<button class="btn btn-sm btn-default" id="MySQLdump"><i class="fa fa-upload"></i> <?php print _ ('Prepare MySQL dump'); ?></button>
70 70
 
71 71
 <!-- XLS dump -->
72
-<h4><?php print _('Create XLS file of IP addresses'); ?></h4>
73
-<button class="btn btn-sm btn-default" id="XLSdump"><i class="fa fa-upload"></i> <?php print _('Prepare XLS dump'); ?></button>
72
+<h4><?php print _ ('Create XLS file of IP addresses'); ?></h4>
73
+<button class="btn btn-sm btn-default" id="XLSdump"><i class="fa fa-upload"></i> <?php print _ ('Prepare XLS dump'); ?></button>
74 74
 
75 75
 <!-- XLS dump -->
76
-<h4><?php print _('Create hostfile dump'); ?></h4>
77
-<button class="btn btn-sm btn-default" id="hostfileDump"><i class="fa fa-upload"></i> <?php print _('Prepare hostfile dump'); ?></button>
78 76
\ No newline at end of file
77
+<h4><?php print _ ('Create hostfile dump'); ?></h4>
78
+<button class="btn btn-sm btn-default" id="hostfileDump"><i class="fa fa-upload"></i> <?php print _ ('Prepare hostfile dump'); ?></button>
79 79
\ No newline at end of file
Please login to merge, or discard this patch.
app/error.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -1,5 +1,5 @@  discard block
 block discarded – undo
1 1
 <?php
2
-$http_codes = array(
2
+$http_codes = array (
3 3
     100 => 'Continue',
4 4
     101 => 'Switching Protocols',
5 5
     102 => 'Processing',
@@ -58,15 +58,15 @@  discard block
 block discarded – undo
58 58
 );
59 59
 
60 60
 // validate
61
-if (!array_key_exists($_REQUEST['section'], $http_codes)) { $_REQUEST['section'] = 404; }
61
+if (!array_key_exists ($_REQUEST['section'], $http_codes)) { $_REQUEST['section'] = 404; }
62 62
 ?>
63 63
 
64 64
 <div class="container" style="margin-top:20px;">
65 65
 <div class="row">
66 66
 <div class="col-xs-12 col-md-6 col-md-offset-3 alert alert alert-danger">
67
-	<strong><h3><?php print _('Oops! Something went wrong!'); ?></h3></strong><hr>
67
+	<strong><h3><?php print _ ('Oops! Something went wrong!'); ?></h3></strong><hr>
68 68
 	<br>
69
-	<?php print _('Provided http error code is'); ?>: <strong><?php print_r($_REQUEST['section']); ?>: <?php print $http_codes[$_REQUEST['section']]; ?></strong>
69
+	<?php print _ ('Provided http error code is'); ?>: <strong><?php print_r ($_REQUEST['section']); ?>: <?php print $http_codes[$_REQUEST['section']]; ?></strong>
70 70
 </div>
71 71
 </div>
72 72
 </div>
73 73
\ No newline at end of file
Please login to merge, or discard this patch.
app/tools/search/index.php 1 patch
Spacing   +18 added lines, -18 removed lines patch added patch discarded remove patch
@@ -3,24 +3,24 @@  discard block
 block discarded – undo
3 3
 /** search form **/
4 4
 
5 5
 # verify that user is logged in
6
-$User->check_user_session();
6
+$User->check_user_session ();
7 7
 
8 8
 # get posted search term
9
-if(@$_GET['ip']) { $searchTerm = htmlspecialchars($_GET['ip']); }
10
-else			 { $searchTerm = ""; }
9
+if (@$_GET['ip']) { $searchTerm = htmlspecialchars ($_GET['ip']); }
10
+else { $searchTerm = ""; }
11 11
 
12 12
 ?>
13 13
 
14
-<h4><?php print _('Search IP database');?></h4>
14
+<h4><?php print _ ('Search IP database'); ?></h4>
15 15
 <hr>
16 16
 
17 17
 <!-- search form -->
18 18
 <form id="search" name="search" class='form-inline' role="form" style="margin-bottom:20px;">
19 19
 	<div class='input-group'>
20 20
 	<div class='form-group'>
21
-		<input class="search input-md form-control" name="ip" value="<?php print $searchTerm; ?>" placeholder="<?php print _('Search term'); ?>" type="text" autofocus="autofocus" style='width:250px;'>
21
+		<input class="search input-md form-control" name="ip" value="<?php print $searchTerm; ?>" placeholder="<?php print _ ('Search term'); ?>" type="text" autofocus="autofocus" style='width:250px;'>
22 22
 		<span class="input-group-btn">
23
-			<button type="submit" class="btn btn-md btn-default"><?php print _('search');?></button>
23
+			<button type="submit" class="btn btn-md btn-default"><?php print _ ('search'); ?></button>
24 24
 		</span>
25 25
 	</div>
26 26
 	</div>
@@ -28,18 +28,18 @@  discard block
 block discarded – undo
28 28
 	<div style="margin:5px;">
29 29
 		<?php
30 30
 		# if all are off print all on!
31
-		if($_REQUEST['subnets']!="on" && $_REQUEST['addresses']!="on" && $_REQUEST['vlans']!="on"  && $_REQUEST['vrf']!="on") {
32
-			$_REQUEST['subnets']="on";
33
-			$_REQUEST['addresses']="on";
34
-			$_REQUEST['vlans']="on";
35
-			$_REQUEST['vrf']="on";
31
+		if ($_REQUEST['subnets'] != "on" && $_REQUEST['addresses'] != "on" && $_REQUEST['vlans'] != "on" && $_REQUEST['vrf'] != "on") {
32
+			$_REQUEST['subnets'] = "on";
33
+			$_REQUEST['addresses'] = "on";
34
+			$_REQUEST['vlans'] = "on";
35
+			$_REQUEST['vrf'] = "on";
36 36
 		}
37 37
 		?>
38
-		<input type="checkbox" name="subnets" 	value="on" <?php if($_REQUEST['subnets']=="on") 	{ print "checked='checked'"; } ?>> <?php print _('Subnets'); ?>
39
-		<input type="checkbox" name="addresses" value="on" <?php if($_REQUEST['addresses']=="on") 	{ print "checked='checked'"; } ?>> <?php print _('IP addresses'); ?>
40
-		<input type="checkbox" name="vlans" 	value="on" <?php if($_REQUEST['vlans']=="on") 		{ print "checked='checked'"; } ?>> <?php print _('VLANs'); ?>
41
-		<?php if($User->settings->enableVRF==1) { ?>
42
-		<input type="checkbox" name="vrf" 	    value="on" <?php if($_REQUEST['vrf']=="on") 		{ print "checked='checked'"; } ?>> <?php print _('VRFs'); ?>
38
+		<input type="checkbox" name="subnets" 	value="on" <?php if ($_REQUEST['subnets'] == "on") { print "checked='checked'"; } ?>> <?php print _ ('Subnets'); ?>
39
+		<input type="checkbox" name="addresses" value="on" <?php if ($_REQUEST['addresses'] == "on") { print "checked='checked'"; } ?>> <?php print _ ('IP addresses'); ?>
40
+		<input type="checkbox" name="vlans" 	value="on" <?php if ($_REQUEST['vlans'] == "on") { print "checked='checked'"; } ?>> <?php print _ ('VLANs'); ?>
41
+		<?php if ($User->settings->enableVRF == 1) { ?>
42
+		<input type="checkbox" name="vrf" 	    value="on" <?php if ($_REQUEST['vrf'] == "on") { print "checked='checked'"; } ?>> <?php print _ ('VRFs'); ?>
43 43
 		<?php } ?>
44 44
 
45 45
 	</div>
@@ -52,7 +52,7 @@  discard block
 block discarded – undo
52 52
 <div class="searchResult">
53 53
 <?php
54 54
 /* include results if IP address is posted */
55
-if ($searchTerm) 	{ include('search-results.php'); }
56
-else 				{ include('search-tips.php');}
55
+if ($searchTerm) { include('search-results.php'); }
56
+else { include('search-tips.php'); }
57 57
 ?>
58 58
 </div>
59 59
\ No newline at end of file
Please login to merge, or discard this patch.