The invention provides 5-substituted-2-(4-substituted phenyl)benzoxazole derivatives. A general structural formula thereof is as follows: when A is Ar, wherein R1 is H, F, Cl, Br, I, NO2, OMe or Me; R2 is H, F, Cl, Br, I, NO2, OMe or Me; R3 is H, F, Cl, Br, I, NO2, NH2, Me, Et, i-Pr, t-But or OMe; R4 is H, F, Cl, Br, I, NO2, OMe or Me; R5 is H, F, Cl, Br, I, NO2, OMe or Me; and R6 is H, F, Cl, Br, I, NO2, OMe or Me. When A is R, A is methyl, ethyl, propyl, chloromethyl, bromomethyl, 2-chloroethyl or 2-bromoethyl. The invention also relates to a method for preparing the compounds and application of the compounds when taken as an influenza virus inhibitor.