Jump to content

[SOLVED] PHP Help...I'm stuck


atl_andy

Recommended Posts

I have a form with several fields that submits data to a postgresql database.  Some additional functionality I would like to add, any help is greatly appreciated:

 

1.  Have a check for duplicates (against data already in the sql database) completed when text is entered in one of the fields.  No duplicate information can be entered.  I would like to perform this check when the text is entered instead of when the form is submitted.

 

2.  When a box is checked, another window pops up to choose other information; when the information is chosen, the base field is populated.  Does php have this functionality?  Is this better handled with another language?

 

3.  When the form data is submitted, display an error if any of the fields are blank.

 

4.  I'm having trouble formatting a query into table format.  Any advice here would be helpful, currently I can only get it to format in a comma-delimmit(sp?) format.

 

Link to comment
https://forums.phpfreaks.com/topic/78982-solved-php-helpim-stuck/
Share on other sites

Thanks for the help.  I used a different method, but you helped me get to the right place.  It was easier to use the following to see if a filed is blank:

 

if (strlen($_POST['serialnumber']) == 0)
   {
       echo "<h2><b>Serial number field cannot be blank!  Go back, enter data and submit form again.<b></h2><br />";
   } 

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.