Wrox Programmer Forums
|
Beginning PHP Beginning-level PHP discussions. More advanced coders should post to the Pro PHP forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Beginning PHP section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old June 30th, 2013, 01:21 AM
Registered User
 
Join Date: Jun 2013
Posts: 2
Thanks: 1
Thanked 0 Times in 0 Posts
Default "submit" button

Hi.
There is a form in which we have several text fields, a checkbox and a "submit" button. If the checkbox is checked by the user, the "submit" button will be activated. I don't know how to do this in PHP or javascript? Plz help me....
 
Old July 4th, 2013, 02:18 AM
Registered User
 
Join Date: Jul 2013
Posts: 11
Thanks: 0
Thanked 1 Time in 1 Post
Default Use jQuery for fast check

I using jQuery:
Code:
$('form').submit(function(){
if ($('[name=checkbox_name]').prop('checked')){
return true;
}else{
alert('Please check agree...');
return false;
}
});
The Following User Says Thank You to cphamtcb For This Useful Post:
sara24 (July 12th, 2013)





Similar Threads
Thread Thread Starter Forum Replies Last Post
MSXSL gives error message for "for" inside "select" ilyaz XSLT 1 December 9th, 2010 05:02 PM
How to theme the "Browse" button of "FileUpload" control? varunbwj BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3 2 October 14th, 2009 01:22 AM
Add a CheckBox DataColumn to my DataGridView, Null format: "" or "True" but Error: F ismailc C# 2005 0 September 25th, 2009 04:56 AM
Code not going as planned: "icicle" vs "savedinstancestate" joopthecat BOOK: Professional Android Application Development ISBN: 978-0-470-34471-2 3 May 3rd, 2009 03:09 PM
Chapter-5 on Intents:ContactPickerTester does not show the button "Pick a Contact" sunilm12 BOOK: Professional Android Application Development ISBN: 978-0-470-34471-2 3 April 15th, 2009 11:55 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.