Tjk Posted May 1, 2006 Share Posted May 1, 2006 [a href=\"http://pastebin.com/692931\" target=\"_blank\"]http://pastebin.com/692931[/a]$pingtime just echos as "ARRAY" on the page at the moment. What I'm trying to do from here is to create a way of registering if a server responds to a ping and if not then display "offline". Any ideas how I could do this from here?((Had to use postbin because of the forum security feature bug)) :)Regards Quote Link to comment Share on other sites More sharing options...
Zane Posted May 1, 2006 Share Posted May 1, 2006 So apparently $pingtime is only an array if the ping was successfulright?so set an IF statement, or my favorite a ternary statement that does this[code]echo is_array($pingtime)?"online":"offline";[/code]note that that would only display offline or onlinethis is a 3rd party scriptit's being moved thereplease post in the correct forum Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.