Valhalla Legends Forums Archive | Web Development | [PHP] Automatic Updater Code

AuthorMessageTime
AC_Drkan
Hmm.. Can't quite figure this one out. This is what my problem is,

I wrote  a script:
http://files.flawgaming.com/ServerStatus/

I wanted it to connect to here:
http://www.flawgaming.com/ServerStatus/UpdateChecker.php

And retrieve the current version, then, download the version if it isn't up to date.

Heres my coding so far:
[code]$UpdateURL = "http://www.flawgaming.com/ServerStatus/UpdateChecker.php";
$CodingVer = 1;

$UPDateCheck = fsockopen($UpdateURL, 80, $errno, $errstr, 5);
echo($errno." ".$errstr."<BR>");
if ($UPDateCheck != NULL) {
echo("ENTERED LOOP<BR>");
$UPDate = fread($UPDateCheck, 1000);
$CheckThis = explode(' ', $UPDate);
Echo($CheckThis[0]." ".$CheckThis[1]."<BR>");
}[/code]
That is for the Update Checker

Now, this is what the Update checker looks like:
[php]
echo($CurrentVersion." ".$CurrentDownload);
$CurrentVersion = 1;
$CurrentDownload = "http://www.flawgaming.com/ServerStatus/";[/php]

Here's where im stumped:
[code]2 No such file or directory[/code]

I check all the paths, and it looks clean, but still not connecting, did i make an error somewhere that im not seeing? Someone care to help a brother out?!


EDIT:
NVM, FIGURED IT OUT!
March 9, 2006, 12:00 AM

Search