Database connection if checkbox ticked

joelseneque 05 Jan, 2010
I have a Newsletter component on my Joomla site.

I am wanting to create a form as to when someone clicks "subscribe me to Newsletter" it will add the details to the database.

Though if they dont tick the checkbox it will not update the database.

Is there a way to manipulate how the form can connect to the database?
GreyHead 05 Jan, 2010
Hi joelseneque,

The simplest way is to write the MySQL query by hand in one of the OnSubmit boxes and use an 'if' clause to decide if it is run or not.

Bob
This topic is locked and no more replies can be posted.