Ver Mensaje Individual
  #1 (permalink)  
Antiguo 29/04/2010, 09:13
DavidBL
 
Fecha de Ingreso: diciembre-2009
Ubicación: España
Mensajes: 380
Antigüedad: 14 años, 4 meses
Puntos: 1
Pregunta Ayuda algo muy sencillo que por algo no funciona

Hola tengo un HTML y un PHP y no me funciona.
a.html
Cita:
<html>
<head></head>
<body>
<form action="a.php">
<input type="text" name="malo" id="malo">
<input type="submit">
</form>
</body></html>
a.php
Cita:
<html>
<head></head>
<body>
<?php
$fp = fopen("a.txt","w"); //abrimos el archivo para escritura
fwrite($fp, "$_POST['malo']");
fclose($fp); //cerramos la conexión y liberamos la memoria
?>
</body>
</html>
Y me sale el siguiente error:
Cita:
Parse error: parse error, expecting `T_STRING' or `T_VARIABLE' or `T_NUM_STRING' in D:\wamp\www\a.php on line 6
Creo que será algo sencillo pero no se porque no va
me podeis ayudar???