Projet

Général

Profil

« Précédent | Suivant » 

Révision 061ac3f3

Ajouté par N0YB il y a presque 10 ans

Better string check

Voir les différences:

usr/local/www/widgets/widgets/gateways.widget.php
71 71
			<td class="vncellt ellipsis" width="100%">
72 72
				<div id="gateway<?php echo $counter; ?>" style="display:inline">
73 73
					<?php
74
						$if_gw = '';
74 75
						if (is_ipaddr($gateway['gateway']))
75
							echo htmlspecialchars($gateway['gateway']);
76
							$if_gw = htmlspecialchars($gateway['gateway']);
76 77
						else {
77 78
							if($gateway['ipprotocol'] == "inet")
78
								echo htmlspecialchars(get_interface_gateway($gateway['friendlyiface']));
79
								$if_gw = htmlspecialchars(get_interface_gateway($gateway['friendlyiface']));
79 80
							if($gateway['ipprotocol'] == "inet6")
80
								echo htmlspecialchars(get_interface_gateway_v6($gateway['friendlyiface']));
81
							if( (htmlspecialchars(get_interface_gateway($gateway['friendlyiface'])) == '') && (htmlspecialchars(get_interface_gateway_v6($gateway['friendlyiface'])) == '') )
82
								echo '~';
81
								$if_gw = htmlspecialchars(get_interface_gateway_v6($gateway['friendlyiface']));
83 82
						}
83
						echo ($if_gw == '' ? '~' : $if_gw);
84
						unset ($if_gw);
84 85
						$counter++;
85 86
					?>
86 87
				</div>

Formats disponibles : Unified diff