Based on learning theory, we adopt a stochastic learning updating rule to investigate the evolution of cooperation in the Prisoner's Dilemma game on Newman-Watts small-world networks with different payoff aspiration levels. Interestingly, simulation results show that the mechanism of intermediate aspiration promoting cooperation resembles a resonancelike behavior, and there exists a ping-pong vibration of cooperation for large payoff aspiration. To explain the nontrivial dependence of the cooperation level on the aspiration level, we investigate the fractions of links, provide analytical results of the cooperation level, and find that the simulation results are in close agreement with analytical ones. Our work may be helpful in understanding the cooperative behavior induced by the aspiration level in society.