metanohi-misc-subsites/subsites/pictures/edit/index.php

31 lines
933 B
PHP
Raw Normal View History

2011-08-02 19:57:57 +02:00
<?php
header('Content-type: text/html; charset=UTF-8');
$img = $_GET['i'];
$info_path = "../info/$img.info";
// Info file
$f = fopen($info_path, 'r');
$c = fread($f, filesize($info_path));
fclose($f);
?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns='http://www.w3.org/1999/xhtml'>
<head>
<meta name='description' content='Edit the info text of a picture. Owner only.' />
<meta http-equiv='content-language' content='en' />
<meta http-equiv='content-type' content='text/html; charset=utf-8' />
<title>Edit info text</title>
</head>
<body>
<form action='edit.php' method='post'>
<input type='hidden' name='image' value='<?php echo $img; ?>' />
<p><textarea name='uptext' rows='10' cols='80'><?php echo $c; ?></textarea></p>
<p><input name='uppass' type='password' /></p>
<p><input type='submit' value='Change text' /></p>
</form>
</body>
</html>