serialize.php 998 Bytes
<?php
if(array_key_exists('not_serialize', $_POST)) {
	$serialize_s = serialize($_POST['not_serialize']);
	$not_serialize_s = $_POST['not_serialize'];
} else {
	$serialize_s = $not_serialize_s=  '';
}

if(array_key_exists('serialize', $_POST)) {
	$serialize_us = unserialize($_POST['serialize']);
	$not_serialize_us = $_POST['serialize'];
} else {
	$serialize_us = $not_serialize_us=  '';
}

?>
<html>
	<head><title></title></head>
	<body>
		
		<form action="serialize.php" method="post">
			<h2>Klartext serilisieren</h2>
			<p><textarea name="not_serialize" cols="50" rows="10"><?php echo $not_serialize_s ?></textarea></p>
			<p><?php echo $serialize_s ?></p>		


			<h2>serilisierte Text zu Klartext</h2>
			<p><textarea name="serialize" cols="50" rows="10"><?php echo $not_serialize_us ?></textarea></p>
			<p><pre><?php echo print_r($serialize_us, true) ?></pre></p>		




		   <input type="submit" value=" Absenden ">
		   <input type="reset" value=" Abbrechen">
		</form>
	</body>
</html>