Get post_type by term_id

You can get the post type that a term’s taxonomy is attached to, if that’s what you mean.

$post_type = get_taxonomy( $term->taxonomy )->object_type[0];

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