<?php
error_reporting(E_ERROR | E_PARSE);
include '../conector.php';

$sql = "SELECT COUNT(*) as total FROM curso";
$result = mysql_query($sql);
$row = mysql_fetch_assoc($result);
echo "Cursos en BD: " . $row['total'] . "\n";

$sql2 = "SELECT id, anno, periodo FROM planilla ORDER BY id DESC LIMIT 5";
$result2 = mysql_query($sql2);
echo "\nPlanillas recientes:\n";
while($row2 = mysql_fetch_assoc($result2)){
    echo "- ID: " . $row2['id'] . ", Año: " . $row2['anno'] . ", Periodo: " . $row2['periodo'] . "\n";
}
?>