Hi everyone! I'm the author of code.mu :)
I'd love to chat with my non-Russian audience. I'm looking for your feedback on the site and the translation quality. Let's chat:)
102 of 110 menu

PHP generación de tabla en un bucle

Veamos un ejemplo de generación de una tabla en un bucle:

<?php $rows = 5; $cols = 5; echo '<table border="1">'; for ($i = 1; $i <= $rows; $i++) { echo '<tr>'; for ($j = 1; $j <= $cols; $j++) { echo '<td>'. $i * $j .'</td>'; } echo '</tr>'; } echo '</table>'; ?>
Español
БеларускаяEnglishРусский
Usamos cookies para el funcionamiento del sitio, análisis y personalización. El procesamiento de datos se realiza de acuerdo con la Política de privacidad.
aceptar todas configurar rechazar