My error will seem familiar, but everyone here who responds to others with a similar problem keeps pointing to responses for this error as it relates to the links.cfg file and NOT the nph-build.cgi file. I just received the following error after my web host let the server my sites reside on run out of disk space and my error relates to the NPH-BUILD.CGI file. This is not a new installation so everyone's response to others with similar errors to "go do a search in the forums on this error" does NOT apply. I have yet to see a response specific to the nph-build.cgi file (and yes I searched) and for an old installation.
This is the error I'm getting after successfully using this script for 6 months:
Error Message : fatal error: Illegal division by zero at /usr/www/interrac/httpd/htdocs/allforwo/cgibin/links/admin/nph-build.cgi line 432, chunk 691.
It occurs right after it attempts to build the ratings. Line 432 and lines near it include the following:
if (exists $votes{$id}) {
$values[$db_rating] = (($values[$db_rating] * $values[$db_votes]) + $rating{$id}) /
($values[$db_votes] + $votes{$id});
$values[$db_rating] = sprintf ("%.2f", $values[$db_rating]);
$values[$db_votes] = $values[$db_votes] + $votes{$id};
print "\tUpdating rating to $values[$db_rating] for link id $id\n";
}
print DBTMP &join_encode(&array_to_hash(0, @values));
}
close DB;
close DBTMP;
Can I get a response specific to the nph-build.cgi file when it attempts to update instead of the links.cfg file that everyone who has responded to people on here with similar errors seems to point everyone to? Thanks!
[This message has been edited by webdiva (edited March 21, 2000).]
This is the error I'm getting after successfully using this script for 6 months:
Error Message : fatal error: Illegal division by zero at /usr/www/interrac/httpd/htdocs/allforwo/cgibin/links/admin/nph-build.cgi line 432, chunk 691.
It occurs right after it attempts to build the ratings. Line 432 and lines near it include the following:
if (exists $votes{$id}) {
$values[$db_rating] = (($values[$db_rating] * $values[$db_votes]) + $rating{$id}) /
($values[$db_votes] + $votes{$id});
$values[$db_rating] = sprintf ("%.2f", $values[$db_rating]);
$values[$db_votes] = $values[$db_votes] + $votes{$id};
print "\tUpdating rating to $values[$db_rating] for link id $id\n";
}
print DBTMP &join_encode(&array_to_hash(0, @values));
}
close DB;
close DBTMP;
Can I get a response specific to the nph-build.cgi file when it attempts to update instead of the links.cfg file that everyone who has responded to people on here with similar errors seems to point everyone to? Thanks!
[This message has been edited by webdiva (edited March 21, 2000).]