Custom Post Type Category Link

Use get_term_link(); for example:

$terms = wp_get_post_terms( $post->ID, 'category');
echo '<ul>';
foreach ($terms as $term) {
    echo '<li><a href="'.get_term_link($term->slug, 'category').'">'.$term->name.'</a></li>';
}
echo '</ul>';

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