We present an X-ray spectral and timing model to investigate the broad and variable iron line seen in the high flux state of Mrk 335. The model consists of a variable X-ray source positioned along the rotation axis of the black hole that illuminates the accretion disc producing a back-scattered, ionized reflection spectrum. We compute time lags including full dilution effects and perform simultaneous fitting of the 2-10 keV spectrum and the frequency-dependent time lags of 2.5-4 vs. 4-6.5 keV bands. The best-fitting parameters are consistent with a black hole mass of approximately 1.3 x 10^7 M_sun, disc inclination of 45 degrees and the photon index of the direct continuum of 2.4. The iron abundance is 0.5 and the ionization parameter is 10^3 erg cm / s at the innermost part of the disc and decreases further out. The X-ray source height is very small, approximately 2 r_g. Furthermore, we fit the Fe L lags simultaneously with the 0.3-10 keV spectrum. The key parameters are comparable to those previously obtained. We also report the differences below 2 keV using the xillver and reflionx models which could affect the interpretation of the soft excess. While simultaneously fitting spectroscopic and timing data can break the degeneracy between the source height and the black hole mass, we find that the measurements of the source height and the central mass significantly depend on the ionization state of the disc and are possibly model-dependent.