<? include $DOCUMENT_ROOT."/zzzfilelist.inc"; ?>
<? include Inc("metootop.inc.php"); ?>
<? $where="enterdata"; include Inc("checkgameaccess.inc.php"); ?>
<center>
<?
	echo "<br><a href='pdftohtml.exe'>".$loc[$loctag[2]+20][$lang]."</a><br>";
	$basedir = $DOCUMENT_ROOT;
	if ($mode=="enter") {
		$nbfile=0;
		MakeList('');
		chdir($basedir.$metoobasedir);
	
		$content=$entereddata;
		$gamenb=$game;
		include Inc("extractdata.inc.php");
#		echo $savefile."<br>";			
?>
<br>
<form action="enterdata.php" method="post">
	<input type="hidden" name="mode" value="insert">
	<input type="hidden" name="game" value="<? echo $game; ?>">
	<input type="hidden" name="fnsave" value="<? echo $savefn; ?>">
	<font class=jaunenormal><? echo $loc[$loctag[2]+15][$lang]; ?> :</font><br>
	<textarea name="savefile" cols=100 rows=20 tabindex=1><? echo $savefile; ?></textarea>
	<br><font class=jaunenormal>
<?
	echo $loc[$loctag[2]+16][$lang]." : ".$savefn."<br>";
?></font>
	<input type="submit" value="<? echo $loc[$loctag[2]+12][$lang]; ?>" tabindex=2>
</form>
<?	}

	if ($mode=="insert") {
		$fp = fopen ($basedir.$metoobasedir.'turn/'.$fnsave, "w");
		fwrite($fp, $savefile);
		fclose($fp);
		echo "<font class='orangeBOLD'><b>".$loc[$loctag[2]+18][$lang]." !</b></font><br>";
	}
	if ($mode!="enter") {
?>
<br>
<form action="enterdata.php" method="post">
	<input type="hidden" name="mode" value="enter">
	<input type="hidden" name="game" value="<? echo $game; ?>">
	<font class=jaunenormal><? echo $loc[$loctag[2]+17][$lang]; ?> :</font><br>
	<textarea name="entereddata" cols=100 rows=20 tabindex=1></textarea>
	<br>
	<input type="submit" value="<? echo $loc[$loctag[2]+12][$lang]; ?>" tabindex=2>
</form>
<?
	}
?>
<? include Inc("metoobottom.inc.php"); ?>