<?php
try {
$db = new PDO("mysql:host=localhost;dbname=test", "kullaniciadi", "sifre");
$db->exec("SET NAMES 'utf8'; SET CHARSET 'utf8'");
}
catch ( PDOException $e )
{ print $e->getMessage();}
?>
index dosyasında en başa

<? include("panel/veritabani.php"); ?>
bu şekilde sorunsuz olması lazım normalde.