if in_category on archive.php

If memory serves, in_category() is for use within the loop and returns true when the current post is in that particular category.

You’re probably for is_category(166).

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