<?php
include_once('./admin_header.php');

echo '<table border="0" cellpadding="0" cellspacing="0" align="center" valign="top" width="100%"><tr><td class="bg2">';
echo '<table border="0" cellpadding="4" cellspacing="1" width="100%">';
echo '<tr class="bg3" align="center"><td colspan=7><b>' . _MD_A_SYNCFORUM . '</b></td></tr>';
echo "</table>";
echo "</table>";
echo "<br><br>";

if ($HTTP_POST_VARS['submit'])
{
		echo _MD_A_SYNCHING . "<br />";
		flush();
		sync(null, "all forums");
		flush();
		sync(null, "all topics");
		echo "<br />";
		echo _DONE;
} 
else
{
?>
		<table border="0" cellpadding="1" cellspacing="0" align="center" valign="top" width="100%"><tr>
		<td class="bg2">
		<table border="0" cellpadding="1" cellspacing="1" width="100%">
		<tr class="bg3" align="left">
		<td><?php echo _MD_A_CLICKBELOWSYNC; ?></td>
		</tr><tr class="bg1" align="center">
		<td>
		<form action="./sync.php" method="post">
		<input type="hidden" name="mode" value="sync">
		<input type="submit" class="button" name="submit" value="<?php echo _MD_A_START; ?>">
		</form>
		</td>
		</td></tr></table>
		</td></tr></table>
<?php
} 

echo '<br><br>';
echo '<table border="0" cellpadding="0" cellspacing="0" align="center" valign="top" width="100%"><tr><td class="bg2">';
echo '<table border="0" cellpadding="4" cellspacing="1" width="100%">';
echo '<tr class="bg3" align="center"><td><input type="button" value="'._MD_A_BACK_TO_FM.'" class="button" onclick="javascript:window.location=\'forum_manager.php\'"></td></tr>';
echo '</table></table>';

CloseTable();
xoops_cp_footer();
exit();

?>
