Is there an alternative to get_template_directory_uri()?

It is a sign that you are “doing it wrong”. you should not assume the existance or initialization of anything before the init action was fired, or even better to wait for wp_loaded

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