form data to database

Issues related to forms.
Post Reply
bennywww
 
 
Posts: 10
Joined: Tue Mar 05, 2019 1:29 pm

form data to database

Post by bennywww »

Hi
unfortunately i need some help
form data into database
gives this error: Failed to insert data into table!
Unknown column 'DATESTAMP' in 'field list'

in phpmyadmin
my form tables are created and FORMID
but there is no primary key
greeting benny
User avatar
Pablo
 
Posts: 21715
Joined: Sun Mar 28, 2004 12:00 pm
Location: Europe
Contact:

Re: form data to database

Post by Pablo »

Does your database table have a 'datestamp' field?
bennywww
 
 
Posts: 10
Joined: Tue Mar 05, 2019 1:29 pm

Re: form data to database

Post by bennywww »

No
Benny
User avatar
Pablo
 
Posts: 21715
Joined: Sun Mar 28, 2004 12:00 pm
Location: Europe
Contact:

Re: form data to database

Post by Pablo »

This is a require field.

See also this related topic:
https://www.wysiwygwebbuilder.com/forum ... =5&t=88407
bennywww
 
 
Posts: 10
Joined: Tue Mar 05, 2019 1:29 pm

Re: form data to database

Post by bennywww »

Hi Pablo
thanks for your prompt reply
i have read the php file
manually created tables
now something is working

all my form dates are written to the database ok
DATE TAMP OK - TIME OK - IP OFF - BROWSER - OK

PROBLEMS WITH DATE
Warning: date (): It is not safe to rely on the system's timezone settings
Hope you have a solution
friendly benny
MGD4me
 
 
Posts: 288
Joined: Tue May 02, 2017 11:56 pm
Location: British Columbia, Canada

Re: form data to database

Post by MGD4me »

Warning: date (): It is not safe to rely on the system's timezone settings
In your php code, it is good practice to declare the time zone, such as:

date_default_timezone_set('America/Vancouver');

... just change the 'America/Vancouver' part to reflect the zone for your region. A list of time zones is available here:

https://www.php.net/manual/en/timezones.php
bennywww
 
 
Posts: 10
Joined: Tue Mar 05, 2019 1:29 pm

Re: form data to database

Post by bennywww »

Hi
thank you for this information
now works without errors
but (DATE) table is empty in database
friendly Benny
Post Reply