Echoing home_url() returns current url in searchform.php

Just like @cjbj says, use home_url() without the slash.

home_url( $path, $scheme ); – $path (string) (optional) Path relative to the home URL.

instead of home_url() you can use bloginfo('url') to get the root/home of your wordpress site.

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