Click here to Skip to main content
15,890,579 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
How can i check the internet connection if its disconnected without redirecting to error page , just shows a messege "that is seems your not connected to internet" Like www.facebook.com or www.live.com .

if your not connected to internet i give u error messege without redirecting ..

please help me in this ,

Regards

A.Abulubbad
Posted

By putting all the code to do it inside your page, so that it makes a call, and if it fails , shows the message.
 
Share this answer
 
Comments
imaa2amha 5-May-10 7:43am    
the server is decide if its fail or not , how should the client know ?!
XML
i found the solution
<script>
navigator.onLine()
</script>
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900