How does that happen? (short of a manual boot order override or not having a bootable disc)
If the bios has it's own F8 boot menu you have the option of overiding the default drive order. Without that a simple miss of the option to load from the cd rom when the short line scrolls results in the auto loading of the primary.
Which is the equivalent of having the optical drive have a higher boot priority as compared to the harddisks. Removing the harddisks from the boot order will not prevent the system from booting off them (on more recent generation motherboards) ... if there is nothing bootable on the optical drives, the machine will then look for the first bootable device.
Would be easier to do a one-time manual boot override
At times when dual OSing here with two instead of one hard drive installed the boot device search would still go right after one of the hard drives due to the mbr detection. In order to insure that the optical is sought you can disable the boot from HD#0, HD#1, and so forth by selecting the cd rom and a quick disable of any hard drive or floppy items in the bios boot order.
I've done this often to force the XP installer to load rather then see corrupted mbr or missing ntldr messages appear. This is a quick method to get the cd rom to be the default device. You only use this setting until the installer completes and auto boots once files are fully copied. You then re-enter the bios after to set the normal boot order. This can also get you around the "failure to detect hard drive" errors that can come up. Give it a try sometime with any bootable cd.
On some systems I've seen the cd rom set as the first three devices and watched it still search for a hard drive! I said wait a minute the cd is in the drive and it still looks for the HD?

Alright! set the boot order to strictly optical and waa laa the cd then decides to load.

At first it sounds ridiculus until you get stuck sometime knowing the cd rom is the first in the boot order and still see it try to autoload from the drive. If the XP cd is more then a simple upgrade disk such as a recovery or full version the installer will then run.
One alternative if you still see your disk boot up and are unable to delete the current and create the new primary would be the Linux Gnome Partition Editor called GParted. To remove the old and create a new NTFS type primary ready for the installer or disk management to format you simply download and burn the iso image onto a cd. But that or Active Killdisk used on a boot floppy shouldn't be needed here.
If your XP cd is still unbootable you would have a bigger problem with a bad installation disk.

You wouldn't be able to reinstall Windows or perform a repair install if and wnenever. The failure to load the installer at that point would then send the bios looking for another boot device. In that case you would use the alternate methods of either downloading and burning GParted live for cd that can create or delete NTFS, Fat32, Fat16, and Linux VFat12 partitions easily. It's a good partitioning tool to have onhand anyways.
http://gparted.sourceforge.net/download.php