PHP

A PHP Times Table Programme

 

 

In the previous part, you saw what a For Loop was.
In this section, we’ll write a times table programme to illustrate how for
loops work.

There’s a script called timesTable.php amongst the files you downloaded (in
the scripts folder). When loaded into the browser, it looks like this:

There’s a script called timesTable.php amongst the files
you downloaded (in the scripts folder.). When loaded into the browser,
it looks like this:

Times Table Programme

What we’re going to do is to get the values from the textboxes and create
a Times Table proramme. When the button is clicked, the output will be something
like this:

PHP Output for a times table program

In other words, when the button is clicked we’ll print the Times Table to
the page. You can have a different Times Table, depending on what values you
enter in the textboxes. To make a start with the coding, move on to the next
part.

|

Kaynak : https://www.homeandlearn.co.uk/php/php5p2.html ‘sitesinden alıntı

Yorum Yap