Multiple stimulus responses of the novel triazine frameworks (1− 2) are constructed by the building block Ln x (COO) y with the reaction of a flexible hexacarboxylic acid 2,4,6-tris(3,5-dicarboxyanilino)-1,3,5-triazine (H 6 TDPAT) and corresponding rare earth nitrate under solvothermal conditions. In a similar reaction condition, we successfully introduced 1,1′-[1,4-phenylbis-(methylene)]bis(4,4′-bipyridine) dichloride (pbpyCl 2 ) into the pores of triazine frameworks and obtained compound 3. The effect of the addition amount of pbpyCl 2 on the framework structure is discussed in detail. Compounds 1−3 are characterized by elemental analysis, infrared spectroscopy, ultraviolet spectroscopy, thermogravimetric analysis, and X-ray powder diffraction. Based on the excellent fluorescence sensing properties of compounds 2 and 3, we also explore the fluorescence sensing on nitro compounds and investigate their mechanisms. The results show that 2 has the best fluorescence response on 2,4,6-trinitrophenol (TNP) and 3 has a sensitive detection ability on p-nitrophenol (PNP) and p-nitroaniline (p-NA).