Assuming that the ribbon cable is standard - you could consider adding TWO IDC connectors, side by side. Then slice the cable through between them. Then add a standard extension cable to link the two. Indeed if one of the two is male, the other female - the extension can be removed if the thing is relocated to where the extension isn’t needed - or a longer one is needed.
I confess to having done this sort of mod several times, myself. It’s also quite an easy way of sticking a protocol analyser/sniffer between the two and/or modifying the data that is sent on its way. Or adding an additional sensor (even of a different type) and converting its output to something suitable.