20 */ |
20 */ |
21 |
21 |
22 require_once('inc/toolkit.inc.php'); |
22 require_once('inc/toolkit.inc.php'); |
23 include_once('inc/header.inc.php'); |
23 include_once('inc/header.inc.php'); |
24 |
24 |
25 if (!(verify_permission(search))) { |
25 if (!(verify_permission('search'))) { |
26 error(ERR_PERM_SEARCH); |
26 error(ERR_PERM_SEARCH); |
27 include_once('inc/footer.inc.php'); |
27 include_once('inc/footer.inc.php'); |
28 exit; |
28 exit; |
29 |
29 |
30 } else { |
30 } else { |
31 echo " <h2>" . _('Search zones and records') . "</h2>\n"; |
31 echo " <h2>" . _('Search zones and records') . "</h2>\n"; |
|
32 $holy_grail = ''; |
|
33 if (isset($_POST['submit'])) { |
32 |
34 |
33 if ($_POST['submit']) { |
35 if (verify_permission('zone_content_view_others')) { $perm_view = "all" ; } |
34 |
36 elseif (verify_permission('zone_content_view_own')) { $perm_view = "own" ; } |
35 if (verify_permission(zone_content_view_others)) { $perm_view = "all" ; } |
|
36 elseif (verify_permission(zone_content_view_own)) { $perm_view = "own" ; } |
|
37 else { $perm_view = "none" ; } |
37 else { $perm_view = "none" ; } |
38 |
38 |
39 if (verify_permission(zone_content_edit_others)) { $perm_edit = "all" ; } |
39 if (verify_permission('zone_content_edit_others')) { $perm_edit = "all" ; } |
40 elseif (verify_permission(zone_content_edit_own)) { $perm_edit = "own" ; } |
40 elseif (verify_permission('zone_content_edit_own')) { $perm_edit = "own" ; } |
41 else { $perm_edit = "none" ; } |
41 else { $perm_edit = "none" ; } |
42 |
42 |
43 $holy_grail = $_POST['query']; |
43 $holy_grail = $_POST['query']; |
44 |
44 |
45 $result = search_zone_and_record($holy_grail,$perm_view); |
45 $result = search_zone_and_record($holy_grail,$perm_view); |