Getting post URL within custom content template

You need to switch get_permalink to the_permalink or echo esc_url(get_permalink).

get_permalink

the_permalink

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