how to check whether application is running in foreground or background

how to check whether application is running in foreground or background

BY 09 Sep 2015 Web Application Development

I’d like to check whether web application is running in foreground or background. is there any function to catch up this one?

Thank in advance.

 

Written by