This paper presents a novel two dimensional (2D) wavelength/time (W/T) code with zero cross correlation property to minimize the multiple access interference (MAI) referred as two dimensional multi-diagonal prime hop code (2D MDPHC) in optical fiber network. This 2D MDPHC code is constructed using various features of two different one dimensional (1D) codes i.e. multi-diagonal code (MD) and prime code (PC). The proposed 2D MDPHC code is generated using java software version 8.1 and implemented in an optical system using the optisystem software version 14 for the spectral amplitude coded optical code division multiple access (SAC-OCDMA) scheme. The proposed 2D MDPHC code exhibits zero cross correlation property which reduces the multiple access interference (MAI) and improves system performance. Simulation results reveal that the OCDMA system based on the proposed 2D MDPHC code can accommodate large number of simultaneous users with higher data rate transmission, lower bit error rates (BER) and longer travelling distance without compromising the signal quality as compared to the existing SAC-OCDMA codes. Further, security provision at the photonic layer of the OCDMA network is addressed by transmitting the data through a novel encrypted circuit in order to prevent the hacking by an eavesdropper or by an unauthorized user to disrupt the communication.