55 of 100 menu

PHP Taskbook Level 6.5

A form with an input is given. The user's date of birth is entered into the input in the format year-month-day. After sending the form, output in a paragraph how many full years the user is.

A form with two inputs is given. Numbers are entered into the inputs, separated by commas. After sending the form, output the numbers that are in both inputs, separated by commas, into a paragraph.

The following array is given:

<?php $arr = [ 'text1', 'text2', 'text3', ]; ?>

Use it to generate the following HTML code:

<ul> <li><a href="index.php?page=1">text1</a></li> <li><a href="index.php?page=2">text2</a></li> <li><a href="index.php?page=3">text3</a></li> </ul>

Modify the previous task so that the link leading to the current page is highlighted with the specified class:

<ul> <li><a href="index.php?page=1">text1</a></li> <li><a href="index.php?page=2" class="active">text2</a></li> <li><a href="index.php?page=3">text3</a></li> </ul>
ptidtrnlms