Il server avevamo pensato che fosse Linux dedicato su uno dei maggiori provider...., ma nel pannello di controllo non ho trovato uno di news
qualsiasi aiuto è sollievo.
config.php
<?php
$password = "ronin16"; /* Set your password here. The default is test. It is recommended you make your own password */
$font = "arial"; /* set your font type here. The default is arial. */
$fontsize = "2"; /* set your font size here. The default is 2. */
$websitename = "Lidap Piemonte"; /* Set the name of your website here */
$websiteurl = "http://www.lidp.net"; /* Set the URL to your website here */
?>
news.php
<html>
<head>
<title>News Lidp Piemonte</title>
</head>
<body bgcolor="#6B859C">
<table height="400" width="600" cellpadding="0" cellspacing="0" border="0" bgcolor="#A0C6E8" align="center">
<tr>
<td width="20">
</td>
<td>
<font face="arial" size="2">
<center><b>News Editor Lidp Piemonte</b></center><br>
<form action="thankyou.php" method="POST">
Posted By: <input type="text" name="name"><br>
Email: <input type="text" name="email"><br>
Title: <input type="text" name="title"><br>
Password: <input type="text" name="password"><br><br>
News:<br> <TEXTAREA ROWS=10 COLS=60 name="news"></textarea><br>
<input type="submit">
</td>
</tr>
</table>
</font>
</body>
</html>
thankyou.php
<?php
include ("config.php");
$filename = 'news.txt';
$date = date("F j, Y, g:i a");
$name = $_POST["name"];
$email = $_POST["email"];
$title = $_POST["title"];
$news = $_POST["news"];
$pass = $_POST["password"];
if ($password == $pass)
{
$file = file_get_contents($filename);
$fp = fopen($filename, "w");
fwrite($fp, "<font face=$font size=$fontsize><B>$title</b> Posted by: <a href=mailto:$email>$name</a><Br><b>Date:</b> $date<br> $news</font><br><br>");
fwrite($fp, $file);
fclose($fp);
?>
<html>
<head>
<title>Crystal News Editor</title>
</head>
<body bgcolor="#6B859C">
<?php echo "<font face=$font size=$fontsize>";
echo "<center><h2>Congratulazioni!!</h2></center>";
echo "<center>La tua news è stata inserita correttamente<Br>";
echo "Go To: <a href=$websiteurl>$websitename</a> | <a href=news.php>Fai un'altra News</a></center></font>";
?>
</body>
</html>
<?php }
else {
echo "Password errata!<a href=news.php>Riprova</a>.";
}
?>



Rispondi quotando