Usually when I select a color from the palettes I made the color selector changed for the foreground color, but now, I don't now why, when I do the same thing the color selector use the background color and so I have to reverse the color selector every time I change color
Could you please explain exactly what you mean when you say "palettes". A screen shot could be very helpful.
Are you by any chance holding down the Alt/Option key while using the Eyedropper Tool? This key is what allows you to sample a new background colour as opposed to sampling a new foreground colour (default).