[security] XSS and SQL injection

This commit is contained in:
Marc Delisle
2009-10-12 21:47:40 +00:00
parent 14645a5035
commit 8ec5434999
5 changed files with 22 additions and 16 deletions

View File

@@ -287,7 +287,7 @@ foreach ($tables as $keyname => $each_table) {
$row_count++;
if ($table_is_view) {
$hidden_fields[] = '<input type="hidden" name="views[]" value="' . $each_table['TABLE_NAME'] . '" />';
$hidden_fields[] = '<input type="hidden" name="views[]" value="' . htmlspecialchars($each_table['TABLE_NAME']) . '" />';
}
if ($each_table['TABLE_ROWS'] > 0) {
@@ -373,7 +373,7 @@ foreach ($tables as $keyname => $each_table) {
<tr class="<?php echo $odd_row ? 'odd' : 'even'; $odd_row = ! $odd_row; ?>">
<td align="center">
<input type="checkbox" name="selected_tbl[]"
value="<?php echo $each_table['TABLE_NAME']; ?>"
value="<?php echo htmlspecialchars($each_table['TABLE_NAME']); ?>"
id="checkbox_tbl_<?php echo $i; ?>"<?php echo $checked; ?> /></td>
<th><label for="checkbox_tbl_<?php echo $i; ?>"
title="<?php echo $alias; ?>" style="<?php echo $ignored ? ' ignored' : ''; ?>"><?php echo $truename; ?></label>