Current time: 02-09-2012, 05:55 AM Hello There, Guest! (LoginRegister)

 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Fixing the Server status - View servers option
06-10-2010, 09:33 AM (This post was last modified: 06-11-2010 12:05 AM by Kevin.)
Post: #1
Fixing the Server status - View servers option
Replace this code in:
includes/status.php

PHP Code:
<?php
//Web Server Status v 1.4, Copyright 2002 By Ryan Schwiebert, visit http://www.schwebdesigns.com/
//This script may be freely distributed providing all copyright headers are kept intact. 

//Concept from:
//Abax Server Status v1.04, Copyright 2002 By Nathan Dickman, visit http://www.NathanDickman.com/
//Location of the live or dead server images
//@author Julio Montoya <gugli100@gmail.com> Beeznest - Fixing the url/port management

//Please change to your server specifications
$live "../themes/icons/lightbulb.png";
$dead "../themes/icons/lightbulb_off.png";

//The status checking script
//meddle at your own risk!
//check for port number, default is 80
$link $_GET['link'];
$s_link basename($link);
list(
$addr,$port)= explode (':',"$s_link");
if (empty(
$port)){
    
$port 80;
}

//Test the server connection
$churl = @fsockopen($addr$port$errno$errstr5);
if (!
$churl){
    
//echo $errstr;
    
header("Location: $dead");
} else {
   
header("Location: $live");             
}
?>

Julio Montoya
BeezNest - http://www.beeznest.com
Blog: http://phpcommit.wordpress.com
Visit this user's website Find all posts by this user
06-10-2010, 12:22 PM
Post: #2
RE: Fixing the Server status - View servers option
What exactly is this fixing? I've already submitted a similar looking file in revision 26.

Kevin Mark - TheHostingTool Lead Developer
Visit this user's website Find all posts by this user
06-10-2010, 12:34 PM
Post: #3
RE: Fixing the Server status - View servers option
(06-10-2010 12:22 PM)Kevin Wrote:  What exactly is this fixing? I've already submitted a similar looking file in revision 26.

The script does not work for me so I fix it check the screenshots:

Works
[Image: a7258983978706.jpg]

Not works
[Image: 01c24e83978717.jpg]

Julio Montoya
BeezNest - http://www.beeznest.com
Blog: http://phpcommit.wordpress.com
Visit this user's website Find all posts by this user
06-10-2010, 06:22 PM
Post: #4
RE: Fixing the Server status - View servers option
What kind of changes did you make? It works fine on every system that I've tested it on.

Kevin Mark - TheHostingTool Lead Developer
Visit this user's website Find all posts by this user
06-10-2010, 06:43 PM
Post: #5
RE: Fixing the Server status - View servers option
If you are talking about 1.2.2 then that makes no sense since all it is doing is a ping. The only times the server status will not work is if the port/IP are incorrect or the server does not allow ICMP.

- KuJoe
▒ LvL8
▒ The Free Web Hosting Guide
▒ FreeWebHostingTalk


PM me for theme conversions @ $15!
Visit this user's website Find all posts by this user
06-11-2010, 12:06 AM
Post: #6
RE: Fixing the Server status - View servers option
(06-10-2010 06:43 PM)KuJoe Wrote:  If you are talking about 1.2.2 then that makes no sense since all it is doing is a ping. The only times the server status will not work is if the port/IP are incorrect or the server does not allow ICMP.

Is it even really pinging it? The script just really sends a request to open a socket.

Kevin Mark - TheHostingTool Lead Developer
Visit this user's website Find all posts by this user
06-11-2010, 12:43 AM
Post: #7
RE: Fixing the Server status - View servers option
Maybe I'm thinking of the wrong script. Doh!

- KuJoe
▒ LvL8
▒ The Free Web Hosting Guide
▒ FreeWebHostingTalk


PM me for theme conversions @ $15!
Visit this user's website Find all posts by this user


Forum Jump:


User(s) browsing this thread: 1 Guest(s)