I am using this small line to select user id from my database , but I can't select it . I don't know why , because the browser doesn't display any error , and I cannot figure where the problem is. Please help me; Excuse me for the language used In this code , because it is Albanian language (the language I use in my country)
<html>
<head>
<title>Krijo nje artikull per kete faqe</title>
<link rel="stylesheet" href="assets/login_form/reset.css">
<link rel="stylesheet" href="assets/login_form/animate.css">
<link rel="stylesheet" href="assets/login_form/styles.css">
<script type="text/javascript" src="tiny_mce/tiny_mce.js"></script>
<script type="text/javascript">
tinyMCE.init({
mode : "textareas",
theme : "advanced",
plugins : "autolink,lists,spellchecker,pagebreak,style,layer,table,save,advhr,advimage,advlink,emotions,iespell,inlinepopups,insertdatetime,preview,media,searchreplace,print,contextmenu,paste,directionality,fullscreen,noneditable,visualchars,nonbreaking,xhtmlxtras,template",
theme_advanced_buttons1 : "save,newdocument,|,bold,italic,underline,strikethrough,|,justifyleft,justifycenter,justifyright,justifyfull,|,styleselect,formatselect,fontselect,fontsizeselect",
theme_advanced_buttons2 : "cut,copy,paste,pastetext,pasteword,|,search,replace,|,bullist,numlist,|,outdent,indent,blockquote,|,undo,redo,|,link,unlink,anchor,image,cleanup,help,code,|,insertdate,inserttime,preview,|,forecolor,backcolor",
theme_advanced_buttons3 : "tablecontrols,|,hr,removeformat,visualaid,|,sub,sup,|,charmap,emotions,iespell,media,advhr,|,print,|,ltr,rtl,|,fullscreen",
theme_advanced_buttons4 : "insertlayer,moveforward,movebackward,absolute,|,styleprops,spellchecker,|,cite,abbr,acronym,del,ins,attribs,|,visualchars,nonbreaking,template,blockquote,pagebreak,|,insertfile,insertimage",
theme_advanced_toolbar_location : "top",
theme_advanced_toolbar_align : "left",
theme_advanced_statusbar_location : "bottom",
theme_advanced_resizing : true,
skin : "o2k7",
skin_variant : "silver",
content_css : "css/example.css",
template_external_list_url : "js/template_list.js",
external_link_list_url : "js/link_list.js",
external_image_list_url : "js/image_list.js",
media_external_list_url : "js/media_list.js",});
</script>
</head>
<body>
<?php
mysql_connect("localhost","login_h","1234");
mysql_select_db("articles");
if(!isset($_COOKIE['zakamezusr'])){
header("Location: login.php");
}
if(isset($_POST['submit'])){
$author_id = mysql_query("SELECT ID FROM users WHERE username ='".stripslashes($_COOKIE['zakamezusr'])."'");
$query = "INSERT into posts (title , post ,date_up , author_id , description) VALUES ('".$_POST['title']."', '".$_POST['post']."', '".$_POST['date_up']."', '$author_id', '".$_POST['description']."')";
mysql_query($query);
?>
<h1>sfafdadfasdfasd</h1>
<?php
}else{
?>
<div id="container" style="removed20%;removed:relative;width:640px;">
<form action="<?php echo $_SERVER['PHP_SELF']; ?>" method="post">
<h1>Krijo nje Artikull te ri</h1>
<table border="0">
<tr><td>Emri i Artikullit</td><td>
<input type="text" name="title" maxlength="60">
</td></tr>
<tr><td>Pershkrimi i Artikuallit</td><td>
<input type="text" name="description" maxlength="60">
</td></tr>
<tr><td>Teksti</td><td>
<textarea class="mult" name="post" ></textarea>
</td></tr>
<tr><th colspan=2><input type="submit" name="submit"
value="Register">
</th></tr> </table>
</form>
</div>
<?php
}
?>
</body>
</html>