Both credit to and credit with have the meaning of attribution. The difference is that credit to emphasizes attribution and credit with emphasizes belonging.
credit to
Attribute; attribute... to (someone or something):
The shortage of rice was credited to lack of rain.
The rice harvest failed due to lack of rain.
Credited:
She credited $100 to my account.
She credited $100 to my account.
2.credit with
credit [also credit to]:
She credited herself with the discovery.
She credited herself with the discovery.
She takes credit for that discovery.
To credit [also credit to]:
She credited your account with the amount of the cheque.
She credited the amount of the check to A credit to your account.
Think or believe that (someone) has (a certain quality or achievement, etc.):
He came to the firm already credited with many honours.
He came to the firm already credited with many honours.
He came to the firm already credited with many honours. When I came to the company, I already had a lot of reputation.
3.credit
n. Credit, reputation; [financial] loan; credit; trust; reputation
vt. Believe, trust; attribute to... , attribute to; praise
credit card?credit card; charge card
on credit?credit