For a person to take a shine to someone else, he or she likes the other person immediately and to a great extent. It is usually used in reference to two people meeting for the first time, or the moment when they begin to get along. The verb take can be conjugated through all its forms.
There is little solid evidence, but most sources agree that this idiom is a variation of an earlier idiom to shine up to someone. This phrase meant to act in a way that will make someone else like you, as a suitor would to the person he or she is pursuing. It is still used, though it is not as popular.