Location: PHPKode > projects > Football/Soccer Website Manager > footballsoccer-website-manager/editimg.php
include "header.php";
	if (($_SESSION['perm'] < "5"))  {
	echo "<font color='#$col_text'>"; die ('You are not authorised to access this section');

$fileId = $_GET['fileId'];

?><font color="#<?php echo $col_text ?>"><?php

$query="SELECT * FROM topic WHERE topic_id= '$fileId'";
while($row = mysql_fetch_array($result))
$topic_image = $row["topic_image"];
$topic_image_name = $row["topic_image_name"];


	if ($_POST['submit'] == 'submit') {

		if(!$_POST['topic_image_name']) {
		?><font color="#<?php echo "$col_text" ?>"><?php die('You must enter a name');

$topic_image_name = $_POST['topic_image_name'];
$query="UPDATE topic SET topic_image_name = '$topic_image_name' WHERE topic_id = $fileId ";
@mysql_select_db($db_name) or die( "Unable to select database");
?> <meta HTTP-EQUIV="Refresh" CONTENT="0; URL=topicmanage.php"> <?php





<title>Edit Order</title>

<form method="post" action="<?php echo $_SERVER['PHP_SELF'];echo "?fileId="; echo "$fileId";?>">

Enter new name for image
<img src="images/topic/<?php echo "$topic_image"; ?>"><br>
<input id="topic_image_name" size="25" name="topic_image_name" value="<?php echo "$topic_image_name" ?>"><br>


<center><br><input type="Submit" name="submit" value="submit">


Return current item: Football/Soccer Website Manager