Foros del Web » Programando para Internet » PHP »

Parse error: syntax error, unexpected $end

Estas en el tema de Parse error: syntax error, unexpected $end en el foro de PHP en Foros del Web. Código PHP: <?  include( "scripts/conexion.php" ); $result  =  mysql_query ( "SELECT  * FROM lecciones_ " ,  $link ); while( $line = mysql_fetch_array ( $result )){  ?>            <?  $box_artista_id_leccion  = ( ...
  #1 (permalink)  
Antiguo 04/08/2010, 21:18
 
Fecha de Ingreso: agosto-2010
Mensajes: 24
Antigüedad: 13 años, 8 meses
Puntos: 1
Parse error: syntax error, unexpected $end

Código PHP:
<? include("scripts/conexion.php");

$result mysql_query("SELECT  * FROM lecciones_ "$link);



while(
$line=mysql_fetch_array($result)){ ?>
          <?  $box_artista_id_leccion = ($line['artista_id_leccion']); ?>
          <div style="width:550px; height:auto; float:left ; border: #CCCCCC 1px solid;

                clear:none; margin:10px 0 10px 0;  ">
            <div style="width:550px; height:40px; background:#F3F3F3;">
              <spam style=" font-size:20px">Tipo de leccion: <? echo($line['tipo_leccion'])?></spam>
              <?php if (($line['box_text']) == 'si')

                

                { echo 
'<img src="images/text_lec.jpg">';

                }

                
?>
              <?php if (($line['box_part']) == 'si')

                

                { echo 
'<img src="images/part_lec.jpg">';

                }

                
?>
              <?php if (($line['box_audio']) == 'si')

                

                { echo 
'<img src="images/audio_lec.gif"  width="40px" height="40px">';

                }

                
?>
              <?php if (($line['box_video']) == 'si')

                

                { 
                
                echo 
'<img src="images/video_lec.jpg">';

                }

                
?>
            </div>
            <div style="padding:5px 0 0 5px; font-size:15px;"><a href="leccion.php?id=<? echo($line['id_leccion'])?>&<? echo($line['titulo_leccion'])?>"><? echo($line['titulo_leccion'])?></a> </div>
          </div>
          <?php
if ($box_artista_id_leccion != '0'){ 
    
$datos mysql_query("SELECT  * FROM artistas WHERE id = ('$box_artista_id_leccion') ",$link);
    while(
$line1=mysql_num_rows($datos)){
        print  
'<div>'.$line1[nombre].'</div>';
    }
}
?>
  #2 (permalink)  
Antiguo 04/08/2010, 21:26
Avatar de carlos_belisario
Colaborador
 
Fecha de Ingreso: abril-2010
Ubicación: Venezuela Maracay Aragua
Mensajes: 3.156
Antigüedad: 14 años
Puntos: 461
Respuesta: Parse error: syntax error, unexpected $end

bueno lo que te falta o te sobra un } creo que es el de esta linea
Cita:
while($line=mysql_fetch_array($result)){ ?>
lo abres pero luego de todas las funciones nunk lo cierras suerte
__________________
aprende d tus errores e incrementa tu conocimientos
it's not a bug, it's an undocumented feature By @David
php the right way

Etiquetas: end, parse, syntax
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 06:07.