This repository has been archived by the owner on Aug 10, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 7
/
usyroles.php
76 lines (63 loc) · 1.89 KB
/
usyroles.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
<?php
// vim: set expandtab tabstop=4 shiftwidth=4 foldmethod=marker fileencoding=utf-8:
/**
* Usuarios y Roles.
*
* PHP version 5
*
* @category SIVeL
* @package SIVeL
* @author Vladimir Támara <[email protected]>
* @copyright 2004 Dominio público. Sin garantías.
* @license https://www.pasosdejesus.org/dominio_publico_colombia.html Dominio Público. Sin garantías.
* @link http://sivel.sf.net
*/
/**
* Usuarios y Roles.
*/
require_once 'aut.php';
require_once $_SESSION['dirsitio'] . '/conf.php';
require_once 'misc.php';
$aut_usuario = "";
autentica_usuario($dsn, $aut_usuario, 12);
$tabla = 'usuario';
encabezado_envia(_("Usuarios"));
echo '<table border="0" width="100%"><tr>
<td style = "white-space: nowrap;background-color:#CCCCCC;" align="center"
valign = "top" colspan="2"><b>' . _('Usuarios')
. '</b></td></tr></table>';
$d = objeto_tabla($tabla);
sin_error_pear($d);
$k = $d->keys();
$titulo = $_DB_DATAOBJECT_FORMBUILDER['CONFIG']['select_display_field'];
if (isset($d->fb_select_display_field)) {
$titulo = $d->fb_select_display_field;
}
$d->find();
while ($d->fetch()) {
$vd = get_object_vars($d);
$t = $vd['nombre'] . " (" . $vd['nusuario'] . ")";
$pk = "";
if (is_array($k)) {
$sep = "";
foreach ($k as $nl) {
$pk .= $sep . $nl . "=".($d->$nl);
$sep = ",";
}
}
echo sprintf(
'<a href = "detusyrol.php?id=%s">
%s</a><br>',
urlencode($pk),
htmlentities($t, ENT_COMPAT, 'UTF-8')
);
}
echo '<pr> </pr><table border="0" width="100%"
style = "white-space: nowrap; background-color:#CCCCCC;"><tr>' .
'<td align = "left">' .
'<a href = "detusyrol.php">' . _('Nuevo') . '</a>' .
'</td><td align = "right">' .
'<a href = "index.php"><b>' . _('Menú Principal') . '</b></a>' .
'</td></tr></table>';
pie_envia()
?>