views:

203

answers:

4

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?

+1  A: 

It is javascript, the code is here

Ólafur Waage
+6  A: 

They use jQuery:

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

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

Daniel Vassallo
why is it a googleapi?
I__
@every: Google is simply hosting the juquery file (CDN)
RandomNoob
@every: Check this out: http://code.google.com/apis/ajaxlibs/documentation/
Daniel Vassallo
Loading your javascript from a (reliable) third-party domain can actually decrease the loading time of your site. Browsers can make simultaneous connections to separate sites, though most limit the number of connections you make to the same site when loading a single page.
Jarrod
+2  A: 

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.

Jarrod
+2  A: 

jQuery

.animate

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

The reason it's behind is z-index

webbiedave