function stripAllSlashes($input) { if (is_array($input)) { $output = array(); foreach ($input as $key => $value) { $output[$key] = stripAllSlashes($value); } return $output; } else { $output = stripslashes($input); return $output; } }
$pvOptions = array('tableName' => 'pageviews', 'dbFields' => array('page' => '/?action=' . $_POST['url']), 'cond' => 'where page="/?action=' . $_POST[oldurl] . '"'); dbUpdate($pvOptions); //update pageview $msg = 'Updated member page'; $msg = '<font color=red><b>' . $msg . '</b></font>'; } } if ($_GET[id]) { $disAdd = 'disabled'; } else { $disEdit = 'disabled'; } $sel = 'select * from memberpages order by url'; $res = mysql_query($sel, $conn) or die(mysql_error()); while ($mp = mysql_fetch_assoc($res)) { $mp = stripAllSlashes($mp); if ($_GET[id] == $mp[id]) { $m = $mp; } $mList .= '<tr> <td><a href="memberPages.php?id=' . $mp[id] . '">' . $mp[url] . '</a></td> <td>' . $mp['file'] . '</td> <td><a href="../?action=' . $mp[url] . '" target=_blank>Link</a></td> </tr>'; } $mList = '<table>' . $mList . '</table>'; $properties = 'type="text" class="activeField"'; ?> <form method=post> <div class="moduleBlue"><h1>Add New Page</h1>