pero me da un error en la untima linea que puede ser
Cita:
Parse error: syntax error, unexpected end of file in C:\wamp\www\Web\insertcore.php on line 46
Código PHP:
<?php
$conx = @mysql_connect("localhost","root","");
if (!$conx)
{
die('could not connect: ' . mysql_error());
}
$schedule=$_POST['schedule'];
$go=$_POST['go'];
$estilo=$_POST['estilo'];
$id=$_POST['id'];
mysql_select_db("eaton", $conx);
$consulta= "SELECT schedule,general_order,style_number from info WHERE schedule='$schedule'";
$resuta= mysql_query($consulta) or die(mysql_error());
$raw =mysql_fetch_array($resuta);
if($raw['schedule']==$schedule and $raw['general_order']==$go and $raw['style_number']== $estilo):
mysql_select_db("eaton", $conx);
$consultas= "SELECT idtx embobinado where schedule='$schedule'";
$resulta= mysql_query($consultas) or die(mysql_error());
$row =mysql_fetch_array($resulta);
if($raw['idtx']==$id )
{
mysql_select_db("eaton", $conx);
$sql="INSERT INTO corecoil (schedule,go,estilo,idtx,statuscore,fechacore)
VALUES ('$schedule','$go','$estilo','$id','Proceso',now())";
}
else {echo "<script language='javascript'>
alert('La unidad no esta reportada en Embobinado.')
window.location='emb.html'</script>";
}
else:echo "<script language='javascript'>
alert('Los datos no coinciden.')
window.location='core.html'</script>";
if (!mysql_query($sql,$conx));
{
//die('Error; ' . mysql_error());
}
mysql_close($conx);
?>
<script language="javascript">
window.location="core.html";
</script>