Ionic solids have no free electrons. Any charged particles (including ions) can carry electric current, but in an ionic solid the ions are trapped in the lattice, and cannot move away from their fixed positions. Solid ionic compounds do not conduct electricity.
In the liquid state the charged ions are able to move around. The positive ions move towards the negative terminal, and the negative ions move towards the positive terminal Thus the current is carried through the liquid, and the compound is able to conduct electricity. Molten ionic compounds do conduct electricity.
When ionic solids are put in water, the polar water molecules attract the ions in the lattice, and pull them into solution. The attractive forces from the water molecules are enough to break down the strong ionic bonds, and so most ionic compounds dissolve in water easily. The charged ions can move freely around the water, so dissolved ionic solids can conduct electricity well.