Is the CD-ROM recognized in BIOS? If not, try swapping your CD and HDD IDE cables. Make sure that the jumper settings are correct. If each of them is on their own IDE channel, they both should be set to master. If the CD-ROM is recognized in BIOS, it is possible that the XP drivers became corrupted, do the following.
With XP under control panel, double click on system, select the hardware tab then device manager. Check your CD-ROM drivers. Is it there. If it is, delete it and then reboot as they might simply have become corrupted (same thing happened once with my DVD). During boot-up, XP will recognize new hardware being installed and will reload correct drivers.