Browse Source

some more small fixes

mpn
theMage 3 years ago
parent
commit
34611ddec0
2 changed files with 4 additions and 4 deletions
  1. 2 2
      php/admin/save.php
  2. 2 2
      templates/edit.tpl

+ 2 - 2
php/admin/save.php

@ -3,8 +3,8 @@ if (!function_exists('check_login')) { include("include.php"); }
3 3
4 4
$fwdid = $_POST['id'];
5 5
6
$host = mysql_real_escape_string( $_POST['hostname'] );
7
$fwd	= mysql_real_escape_string( $_POST['forward'] );
6
$host = $dbconnect->escapeSimple( $_POST['hostname'] );
7
$fwd	= $dbconnect->escapeSimple( $_POST['forward'] );
8 8
$active = $_POST['active'] ? 1 : 0;
9 9
10 10
if (!$host || !$fwd) { get_error(); }

+ 2 - 2
templates/edit.tpl

@ -6,8 +6,8 @@
6 6
			<tr><th>Forward:</th><td><input name="forward" value="{$forward.forward}"></td></tr>
7 7
			<tr><th>Active:</th><td>
8 8
				<select name="active">
9
					<option value="0" {if $forward.active == 0}selected="selected"{/if}>No</option>
10
					<option value="1" {if $forward.active == 1}selected="selected"{/if}>Yes</option>
9
					<option value="0" {if $forward.active == ""}selected="selected"{/if}>No</option>
10
					<option value="1" {if $forward.active == "1"}selected="selected"{/if}>Yes</option>
11 11
				</select>
12 12
			</td></tr>
13 13
			<tr><th colspan="2"><input type="submit" Value="Save" /></th></tr>