I just made my web in localhost, everything was just fine until I updates my xampp to newer version. And my web now is on a mess.

	<div class="headerStyle">
	$result = mysql_query("SELECT * FROM kategori_berita") or die(mysql_error());
	echo '<ul>';
	while ($data=mysql_fetch_array($result)){
		if ($_REQUEST['catid']==$data['id'])
			echo '<li style="color:#000;">'.$data['kategori'].'</li>';
			echo '<li><a class="newsCategory" href="./?catid='.$data['id'].'">'.$data['kategori'].'</a><br/></li>';
	echo '</ul>';

here's the code and it shows me :
Notice: Undefined index: catid in C:\Program Files\xampp\htdocs\pbd\include\kategori_berita.php on line 9

I'm still new at PHP, so please if you could teach me I would appreciate it :twisted:

This happens when a variable isn't set properly. In this case it's your $_REQUEST variable. When using data pulled through REQUEST, POST, GET, or COOKIE you should always verify that is has a value prior to using it


if (isset($_REQUEST['catid'])

  //Variable is set so do what you want with it


  //Variable is not set so toss error back to user


That being said it is generally advisable not to use $_REQUEST it is bad practice and opens a lot of security issues. Use the appropriate $_POST, $_GET, or $_COOKIE instead.