Understanding PHP Conditional Statements with Gravity Forms gform_after_submission hook

Can anyone point me to a site that could help me learn how to add a conditional statement into php for my gforms_aftermission hook in gravity forms

I use the code below to send submissions to a MySQL database, this works fine on every submission but now I'd like it to work only if a formfield result equals specific text.

Like a If statement in Excel, If X = Y then gforms_aftermission if not take no action

add_action("gform_after_submission_99", "go_contact", 10, 2);
function go_contact($entry, $form){

$First_Name = $entry["5.3"];

$con=mysqli_connect("***IP Address**","**Username**","**Password**","**Database Name**");

mysqli_query($con,"INSERT INTO trs_contact (First_Name) VALUES ('$First_Name')");
} 

Any help/input would be appreciated.

Thanks

How many English words
do you know?
Test your English vocabulary size, and measure
how many words do you know
Online Test
Powered by Examplum