开发者

Birds on the trees in the background

开发者 https://www.devze.com 2023-01-02 19:38 出处:网络
How do these birds pop up behind the trees on the bottom? http://grabaperch.com/about Are they开发者_开发问答 using css with php or what is it?They use jQuery:

How do these birds pop up behind the trees on the bottom?

http://grabaperch.com/about

Are they开发者_开发问答 using css with php or what is it?


They use jQuery:

<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script> 

They have some JavaScript code in perch.js that animates the birds and the trees.


They are using jQuery to animate the birds and trees. There is an animate function that pops the birds out from behind the trees - adjusting the z-index will properly layer elements in that fashion.


jQuery

.animate

http://api.jquery.com/animate/

The reason it's behind is z-index


It is javascript, the code is here

0

精彩评论

暂无评论...
验证码 换一张
取 消