Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $news_t=array(
- "titolo"=>$_POST["titolo"],
- "autore"=>$_POST["autore"],
- "contenuto"=>$_POST["contenuto"],
- "generi"=>$_POST["generi"],
- "data_creazione"=>$_POST["data_creazione"]
- );
- $file=fopen("array.txt", "w");
- for($i=0;$i<count($news_array);$i++) {
- $out="";
- if($i!=$indice)
- foreach ($news_array[$i] as $key => $value)
- $out.=$value."|";
- else
- foreach ($news_t as $key => $value)
- $out.=$value."|";
- $out=substr($out, 0,-1)."\n";
- fwrite($file,$out);
- }
- fclose($file);
- header("Location:index.php");
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement