delete.php

back


<?php

require_once('classes/deleteClass.php');

// Includes the class file to delete a row of data in the database.

$id=$_GET['id'];

// The primary key of the row to be deleted is passed through URL from index.php and hence pulled through $_GET array.

$delete=new deleteClass();

// Creates new object of class deleteClass.

$delete=$delete->deleteFunction($id);

// Passes the primary key, $id as an argument to the function deleteFunction of class deleteClass.

?>