Problems with delete in MYSQL

Hi,

I am new to the list and I would like to get some advice on SQL coding from time to time. I am currently working my way through Kevin Yank’s excellent tutorial and have hit a snag.

The control file, “index.php” tries to detect the “deletejoke” flag coming from the jokes.html.php file with the line:

if (isset($_get[‘deletejoke’]))

{

but fails to detect it.

The jokes.html.php file sets up the “deletejoke” flag when the user presses the delete button on a particular joke with:

<form action=“?deletejoke” method=“post”>

I have tried various simple tests like displaying a simple message from the error.html.php file if the “deletejoke” flag is detected, but nothing happens. I think this means that the “deletejoke” flag is not being passed from jokes.html.php to index.php. I cannot find any reason for this since the other flags are all passing through and I am able to list the jokes and add new ones at will.

Any ideas?

All the best,

Cearbhall

<snip />

Welcome @comanna; and I am pleased you have chosen to join us and ask for some guidance.
Based on your brief description I believe the problem is simply that


if (isset($_get['deletejoke']))

{

should be


if (isset($_GET['deletejoke']))

{