When both Master and Slave jumper-settings fail, it's mostly the setup itself which is funny.
Could you take a look in the computer's BIOS?
There should be an option to set which drives are what in the "Basic BIOS settings" - also called many other things, but always simple, easy (you get the gist of it). Sometimes provided that the drive is detected at all...
However, please check for things such as bent connector-pins on the CD-R drive and on the Mobo's PATA-connector (where you plug in the ribbon, FYI)
But the reason can also be because of the ribbon itself. I've seen customers failing with their setups because of the so called 24-wire ribbon, which nearly looks exactly like the 40-wire ribbon. If there is a newer ribbon laying around; maybe you should try it instead?
And finally, the fact that the CD-R disc-tray can open/close and that the LED is flashing and such?
Sorry to say, but that is only indicating that the CD-R has power, and has more or less nothing to do with the detection problem.