1 | <?php |
||||
2 | session_start(); |
||||
3 | include 'config/koneksi.php'; |
||||
4 | |||||
5 | if ($_SESSION[role] == 'dev') { |
||||
6 | $sql = mysql_query("select * from modul where aktif='Y' order by urutan"); |
||||
0 ignored issues
–
show
|
|||||
7 | } elseif ($_SESSION[role] == 'admin') { |
||||
8 | $sql = mysql_query("select * from modul where status !='dev' and aktif='Y' order by urutan"); |
||||
0 ignored issues
–
show
The function
mysql_query() has been deprecated: 5.5 Send a MySQL query
(
Ignorable by Annotation
)
If this is a false-positive, you can also ignore this issue in your code via the
This function has been deprecated. The supplier of the function has supplied an explanatory message. The explanatory message should give you some clue as to whether and when the function will be removed and what other function to use instead. ![]() |
|||||
9 | } elseif ($_SESSION[role] == 'user') { |
||||
10 | $sql = mysql_query("select * from modul where status='user' and aktif='Y' order by urutan"); |
||||
0 ignored issues
–
show
The function
mysql_query() has been deprecated: 5.5 Send a MySQL query
(
Ignorable by Annotation
)
If this is a false-positive, you can also ignore this issue in your code via the
This function has been deprecated. The supplier of the function has supplied an explanatory message. The explanatory message should give you some clue as to whether and when the function will be removed and what other function to use instead. ![]() |
|||||
11 | } else { |
||||
12 | $sql = mysql_query("SELECT * FROM modul a inner join usermenu b on a.id_modul = b.id_modul where a.status='user' and a.aktif='Y' and b.m_aktif='Y' and b.username='$_SESSION[id_user]' ORDER BY a.urutan"); |
||||
0 ignored issues
–
show
The function
mysql_query() has been deprecated: 5.5 Send a MySQL query
(
Ignorable by Annotation
)
If this is a false-positive, you can also ignore this issue in your code via the
This function has been deprecated. The supplier of the function has supplied an explanatory message. The explanatory message should give you some clue as to whether and when the function will be removed and what other function to use instead. ![]() |
|||||
13 | } |
||||
14 | |||||
15 | while ($r = mysql_fetch_array($sql)) { |
||||
0 ignored issues
–
show
The function
mysql_fetch_array() has been deprecated: 5.5 Fetch a result row as an associative array, a numeric array, or both
(
Ignorable by Annotation
)
If this is a false-positive, you can also ignore this issue in your code via the
This function has been deprecated. The supplier of the function has supplied an explanatory message. The explanatory message should give you some clue as to whether and when the function will be removed and what other function to use instead. ![]() |
|||||
16 | |||||
17 | //$nt=mysql_query("select count from notice where (status = '1' and id_user2 = '$_SESSION[id_user]') or( status = '3' and id_user2 = '$_SESSION[id_user]')"); |
||||
18 | //$cjml = mysql_num_rows($nt); |
||||
19 | |||||
20 | //if ($cjml == '0') { |
||||
21 | //$njml =''; |
||||
22 | //} else { |
||||
23 | //$njml = '('.$cjml.')'; |
||||
24 | //} |
||||
25 | |||||
26 | if ($r[status_menu] == 'M' and !empty($r[link])) { |
||||
27 | if ($r[nama_modul] == 'Notice') { |
||||
28 | echo "<a class='menuitem' href='$r[link]'>$r[nama_modul] $njml</a>"; |
||||
29 | } else { |
||||
30 | echo "<a class='menuitem' href='$r[link]'>$r[nama_modul]</a>"; |
||||
31 | } |
||||
32 | } elseif ($r[status_menu] == 'M' and empty($r[link])) { |
||||
33 | echo "<a class='menuitem submenuheader' href='$r[link]'>$r[nama_modul]</a> "; |
||||
34 | |||||
35 | if ($_SESSION[role] == 'dev' or $_SESSION[role] == 'admin') { |
||||
36 | $detil = mysql_query("select * from modul where id_submenu='$r[id_modul]' and status_menu='C' and aktif='Y' order by urutan"); |
||||
0 ignored issues
–
show
The function
mysql_query() has been deprecated: 5.5 Send a MySQL query
(
Ignorable by Annotation
)
If this is a false-positive, you can also ignore this issue in your code via the
This function has been deprecated. The supplier of the function has supplied an explanatory message. The explanatory message should give you some clue as to whether and when the function will be removed and what other function to use instead. ![]() |
|||||
37 | } else { |
||||
38 | $detil = mysql_query("select * from modul where id_submenu='$r[id_modul]' and status_menu='C' and aktif='Y' and (id_role = '5' or id_role = '$_SESSION[role]') and (id_group = '1' or id_group = '$_SESSION[group]')order by urutan"); |
||||
0 ignored issues
–
show
The function
mysql_query() has been deprecated: 5.5 Send a MySQL query
(
Ignorable by Annotation
)
If this is a false-positive, you can also ignore this issue in your code via the
This function has been deprecated. The supplier of the function has supplied an explanatory message. The explanatory message should give you some clue as to whether and when the function will be removed and what other function to use instead. ![]() |
|||||
39 | } |
||||
40 | echo" |
||||
41 | <div class='submenu'> |
||||
42 | "; |
||||
43 | while ($d = mysql_fetch_array($detil)) { |
||||
0 ignored issues
–
show
The function
mysql_fetch_array() has been deprecated: 5.5 Fetch a result row as an associative array, a numeric array, or both
(
Ignorable by Annotation
)
If this is a false-positive, you can also ignore this issue in your code via the
This function has been deprecated. The supplier of the function has supplied an explanatory message. The explanatory message should give you some clue as to whether and when the function will be removed and what other function to use instead. ![]() |
|||||
44 | echo"<ul><li><a href='$d[link]'>$d[nama_modul]</a></li></ul>"; |
||||
45 | } |
||||
46 | echo' |
||||
47 | </div> |
||||
48 | '; |
||||
49 | } else { |
||||
50 | echo''; |
||||
51 | } |
||||
52 | } |
||||
53 | ?> |
||||
54 | |||||
55 |
This function has been deprecated. The supplier of the function has supplied an explanatory message.
The explanatory message should give you some clue as to whether and when the function will be removed and what other function to use instead.