Redirect all users to dashboard unless custom post type

The earliest hook that is_singular() will work on is wp. replace init with wp in your add_action call

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