Jump to content

Nebox

New Members
  • Posts

    8
  • Joined

  • Last visited

Nebox's Achievements

Member

Member (2/5)

0

Reputation

  1. Thanks, Well intelligent code is a problem since the users that post their server to the listing will have to do something in their side ( in case its curl responding ) which is a little bad idea because more often people are not willing to do anything except giving the best ever description about their game server.
  2. Well thats used for getting information on server's current status ( such as map and players online ) thats a totally different story i thought about checking the status with fsockopen for the monitoring for example $current_status = ''; $server_status = @fsockopen($TMPL['server_ip'], $TMPL['server_port'], $errno, $errstr, 1); if($server_status >= 1){ $TMPL['current_status'] = 'Online'; fclose($server_status); }else{ $TMPL['current_status'] = 'Offline'; } I actually have all the features except the monitoring, so yeah, my goal is to make a chart with server status history by percentage Basically my problem was is lack of knowledge of how should i record the status to the database, to maybe a json file or db ( mysql ) or what should it actually record during 24 hour period, like do i record the exact time etc, how should my table designed ( ip | port | timestamp | status ) o.o also i'm still not sure of how do i make script run automatically without leaving the script open and exploitable in case if someone will figure out somehow to send packets to the php file located link
  3. I agree with requinix, the short_open_tag is disabled, you might want to take a look at PHP.ini Though it wasn't good idea writing scripts with the short tags in first place, full tag is safer to use.
  4. I guess i just don't know how to explain what i actually want to do so i'll just show you an example. I want to make a plugin for website with bunch of private gaming servers ( right now its only Counter Strike servers ) basically game servers listing website. The closest thing to what i want to do is this -> http://minecraftservers.org/server/119693 click on right column on "Stats" and than select Uptime. so you don't waste time searching the buttons here is a screenshot where to click As you see this website top has a lot of servers registered, i have something similar
  5. Nah, i kinda quick-checked the sql you showed me, and started thinking that it might be a nice idea of making a total amount for 24 hours ( lats say 48 if its checked every 30 min ), than in the chart i could generate percentage out of the total number, guess i messed up a little
  6. Oh requinix Its almost what i wanted to know, but isn't that weird adding in uptime +1 instead of writing the current time? Well actually i guess this method is the most optimized since 1 server row every day will be created, and i don't need exact hours anyway. gizmola, I always used curl on two-end scripts ( 1 part located on 1 server and other part on other ), are you sure i should use curl and not just simple pinging? the second thing you said is very interesting, thats a really good thing to do since we don't wanna overload anything right, but how ? ;o if you could show a small example i would really appreciate it. As for 3rd thing, chart isn't a problem, i'll use google or bootstrap charts for this one. Tonight i'll start coding the script
  7. I wanna do this kind of chart, i need some example of the php side for recording uptime data etc I just cant understand how should i write the script =/ ( server uptime monitoring ) getting timestamp and server status for the ip like every hour and than in database i'll have a lot of servers with 24 records every day ? i'm really confused on how to do it, this is why i need some example or explanation :C ps. there will be around 100-200 ips in the database so i have to think of something really simple and optimized
  8. Hello everyone, Could anyone show me an example or recommend some simple script to record server uptime statistics during 7 days, so i could use it automatically for multiple ip:port located in database and than display as chart on selected server page. I need it to be as simple as possible, i need at least an example just to understand the right way doing it so i could build this "plugin" for my website.
  9. Nebox

    Hello

    Hey everyone, I am a web designer and partly web developer, my php knowledge is higher than basic but i still have a lot to learn more. Joined the forums to learn more and get some help over here when i need it
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.