Home > Web Front-end > JS Tutorial > How to write jquery to exit each loop_jquery

How to write jquery to exit each loop_jquery

WBOY
Release: 2016-05-16 16:58:06
Original
1004 people have browsed it

Just return false in the callback function, most jq methods are like this
============================== ======
Returning 'false' will stop the loop (just like using 'break' in a normal loop).
Return 'true' to jump to the next loop (just like using 'continue' in a normal loop).

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template