using the loop in custom meta is messing up ‘add new’ post type

After you create a custom loop, you need to restore the global post variables with wp_reset_query().

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