The tube is identical and can be used on all Compact Macs.
However the coil of the Yoke has to be identical: just swap the complete Yoke Coil with the connector and you're good.
Definately not swap the connector only.
It's an easy and straight forward job. Carefull not to overtighten then screw that keeps the coil in place, otherwise the bulb will brake.