Search code examples
phpechocall

How to call/echo php function on 2nd php page


i want to create a process.php function where i want that php generate random number, and i want that these numbers should be shown in 2nd page. i don't know how to call this function on 2nd page because i am newbie in php. Here is my code which i am trying to implement.

mt_srand(mktime());
echo(mt_rand());

These random numbers generated by php should be shown on 2nd page i.e final.php when applying echo function like this:
04572579
Thanks in advance


Solution

  • in the second page, you need first to include your first page then you can call your function easy as you want