| Index
» Projekty
» phpMyEdit
» Fórum
» Date Functions Don't work |
 |
Craig
Založený: 10.08.2009
Príspevky: 2
Zaslal: 2009-08-10 01:10
Návrat hore
Odpovedať s citátom
|
When creating/Editing a record in this program for a date field it displays it in a greyed out box saying "CURRENT_TIMESTAMP" but when it saves the record it completely fails and saves it as 0000-00-00 00:00:00
I don't want a calendar script since this is an added date and the user is to have no control over. Why doesn't this work?
|
doug
Založený: 10.02.2003
Príspevky: 1013
Bydlisko: Denver, Colorado (USA)
Zaslal: 2009-08-11 16:39
Návrat hore
Odpovedať s citátom
|
It would be helpful if you would post the code from your script along with the MySQL table schema.
If it's a TIMESTAMP column as opposed to DATETIME, DATE, or TIME field, the following example might work for you.
| Kód: |
$opts['fdd']['updated'] = array(
'default' => 'CURRENT_TIMESTAMP',
'overwrite' => 'R',
'maxlen' => 19,
'name' => 'Updated',
'options' => 'VD',
'select' => 'T',
'size' => 19,
'sqlw' => 'TRIM("$val_as")',
'sort' => true
); |
|
Craig
Založený: 10.08.2009
Príspevky: 2
Zaslal: 2009-09-09 21:46
Návrat hore
Odpovedať s citátom
|
Sorry for the delay. I just wanted to say thanks. That worked great. Much appreciated.
|
|
Odoslať novú tému
Odpovedať na tému
|
|
|
|