Input Property

Issues related to forms.
Post Reply
User avatar
jPaul
 
 
Posts: 37
Joined: Thu Jun 10, 2021 11:00 am

Input Property

Post by jPaul »

Hi Everybody,

Which property of an editBox (or any input control) is used to pass the
content of that control? Like $value = ???
Many Thanks,
-Paul-
User avatar
Pablo
 
Posts: 22472
Joined: Sun Mar 28, 2004 12:00 pm
Location: Europe
Contact:

Re: Input Property

Post by Pablo »

In which context? Do you mean in JavaScript?

Note that these are all standard HTML elements so if you are creating a script then this is not specific to WWB.
gvr
 
 
Posts: 54
Joined: Wed Sep 02, 2009 2:07 pm

Re: Input Property

Post by gvr »

If you want to get the value of an edit box in JavaScript, it’d normally look something like document.getElementById('yourElementId').value. Even if you’re using jQuery, it’s even simpler with $('#yourElementId').val().
User avatar
jPaul
 
 
Posts: 37
Joined: Thu Jun 10, 2021 11:00 am

Re: Input Property

Post by jPaul »

Thanks, fellows,

When someone enters their information into a form control, such as an editBox: The editBox ID is fName and they enter "Peter".

When they press the <SUBMIT> button, the idea is to either update or create a new record in a MySQL table. What property of the editBox contains "Peter" so that the PHP statement $FirstName="Peter"?
Many Thanks,
-Paul-
User avatar
Pablo
 
Posts: 22472
Joined: Sun Mar 28, 2004 12:00 pm
Location: Europe
Contact:

Re: Input Property

Post by Pablo »

When a form is submitted the value will be put into a $_POST variable:
https://www.php.net/manual/en/reserved. ... s.post.php

Note that this is not specific to WWB. This is standard PHP functionality.
Post Reply