This paper aims to enable the two-keying approach in spectral-amplitude coding optical code-division multiple-access (SAC-OCDMA) system that employs modified double weight (MDW) code. To achieve this goal, two-keying subtraction detection (TKSD) is suggested, which also declines the impact of multiuser interference (MUI) and phase-induced intensity noise (PIIN). The results of simulation test demonstrate that the TKSD is efficient in realizing the two-keying detection feature in SAC-OCDMA system with superior bit-error rate (BER) performance, security, and transmission rate.