Using WP functions such as the_title() in an included php file

Get the title into a variable, and use the variable in the included PHP instead:

$title = get_the_title();
include "yourfile.php";

yourfile.php:

<?php
echo $title;
?>

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)