Code:
 
<?php 
include('auth.php');
ob_start();
include('config.php');





$title=$_POST['title'];
$content=$_POST['text1'];
$titles=$_POST['title1'];
$contents=$_POST['text2'];

$file = basename($_FILES['img']['name']);
if($file)
{
//exit(var_dump($_FILES));
$file=time().$file;
$target_path = dirname(_FILE_).
...