For any condition involving the muscles/bones in the feet, x-rays are usually taken to assess health of bones and joints to help determine cause of pain.  There are also a couple of skin conditions on the feet that may need x-rays to see if what is happening on the skin (ulcer, callus, corn) has a connection with the bones underneath.