Cytat(wookieb @ 23.02.2009, 15:22:57 )

google -> cron
google -> crontab
Nawet na wikipedii o tym jest
to skoro taki mądry jesteś to może byś podał skypt odpowiednio dostosowany?
Cytat(wookieb @ 23.02.2009, 15:22:57 )

Jaki przycisk?
ten:
<?php
if ( isset($_POST['localfile'])) {
if (file_exists('data/'.MAP_FILE_GZ) AND filesize('data/'.MAP_FILE_GZ)) {
$data = file_get_contents("compress.zlib://data/".MAP_FILE_GZ);
$data_array = explode("\n", $data);
$query = 'TRUNCATE TABLE '.PREFIX.'x_world';
mysql_query($query) OR die(PREFIX.'x_world: '.mysql_error());
while (list($var, $val) = each($data_array)) {
++$var;
$val = trim($val);
$val= str_replace("x_world", PREFIX."x_world", $val);
// printing 5 lines for testing
if ($var < 5) {
print "Line $var: $val <br />";
} elseif ($var == 5) { print "........ <br />";}
// checking if query is proper
$check_sql = strpos($val,'INSERT INTO `'.PREFIX.'x_world` VALUES (');
if (( $check_sql !== false) AND ($check_sql == 0)) {
mysql_query($val) OR die(text('error').' '.$val. ' - '.mysql_error());
}
}
echo '<h4>'.text('upd_finished').'</h4>';
} else {
echo '<h4>'.text('upd_error_1').' ('.MAP_FILE_GZ.')</h4>';
echo '<p style="color:red">'.text('operation_unsuccesfull').'</p>';
}
}
?>