Changeset 1818 for trunk/wp-admin/templates.php
- Timestamp:
- 10/19/2004 03:03:06 AM (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/templates.php
r1703 r1818 1 1 <?php 2 require_once('../wp-includes/wp-l10n.php'); 3 2 require_once('admin.php'); 4 3 $title = __('Template & file editing'); 5 4 $parent_file = 'themes.php'; 6 7 function add_magic_quotes($array) {8 foreach ($array as $k => $v) {9 if (is_array($v)) {10 $array[$k] = add_magic_quotes($v);11 } else {12 $array[$k] = addslashes($v);13 }14 }15 return $array;16 }17 5 18 6 function validate_file($file) { … … 32 20 } 33 21 34 if (!get_magic_quotes_gpc()) { 35 $_GET = add_magic_quotes($_GET); 36 $_POST = add_magic_quotes($_POST); 37 $_COOKIE = add_magic_quotes($_COOKIE); 38 } 39 40 $wpvarstoreset = array('action','standalone','redirect','profile','error','warning','a','file'); 22 $wpvarstoreset = array('action','redirect','profile','error','warning','a','file'); 41 23 for ($i=0; $i<count($wpvarstoreset); $i += 1) { 42 24 $wpvar = $wpvarstoreset[$i]; … … 57 39 58 40 case 'update': 59 60 $standalone = 1;61 require_once('./admin-header.php');62 41 63 42 if ($user_level < 5) {
Note: See TracChangeset
for help on using the changeset viewer.