addaction.php

back


<?php

require_once('classes/addClass.php');

// Includes the class file to add data to database.

$name=$_POST['name'];

// Pulling the value submitted by the user in the form through the associative array $_POST.

$add=new addClass();

// Creates new object of class addClass.

$add->addFunction($name);

// Passes the user passed value to the function addFunction of the class addClass, as an argument.

?>