Displaying Post Featured Images on All Pages

The $id variable isn’t defined. Add this just before the conditional statement:

$id = get_the_ID();

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