Platon Technologies
neprihlásený Prihlásiť Registrácia
SlovakEnglish
open source software development oslavujeme 10 rokov vývoja otvoreného softvéru! Streda, 25. november 2026
O nás
Magazín
Otvorený softvér
CVS
Služby
Index  »  Projekty  »  phpMyEdit  »  Fórum  »  Cannot get time editing

phpMyEdit General     Cannot get time editing
Odoslať novú tému   Odpovedať na tému    
 
msta     Založený: 15.09.2008   Príspevky: 24  
Príspevok Zaslal: 2008-10-06 20:00
Návrat hore  Odpovedať s citátom     

I have placed a collumn, on which a time shall be displayed. The time shall be in format (hh:mm).
In MySQL the "time" collumn type was selected. This gives standard format (hh:mm:ss).

Regardles of what kind of cell formating I use I always get in editing windows a format ready to change (00:00:00).

I use the following format to enter a time:


$opts['fdd']['Time'] = array(
'name' => 'Time',
'select' => 'T', //also tried 'N'
'maxlen' => 8,
'datemask' => date('H:i'), //also tried 'H:i:s'
);

$opts['fdd']['DepartureTime']['js']['regexp'] =
'^([0-1][0-9]|[2][0-3])(:([0-5][0-9])){1,2}$'; // checking that format (hh:mm) was entered
$opts['fdd']['DepartureTime']['js']['hint']
= 'Enter time in format hh:mm';

It is simple code but is not working.
When I enter any time in edit mode, then the time is memorized by MySQL byut is not dispalyed at all in read mode.

Besides the java script (two last lines) does not work at all.

Someone can help to solve this easy looking problem?

Marek

 
ajh     Založený: 17.12.2003   Príspevky: 236  
Príspevok Zaslal: 2008-10-07 11:52
Návrat hore  Odpovedať s citátom     

Try treating it as a calendar field. I think that you already are using the mce_cal extension. jsCalendar can act as time entry as well as date entry.

 
Odoslať novú tému   Odpovedať na tému    

Copyright © 2002-2006 Platon Group
Stránka používa redakčný systém Metafox
Na začiatok · Odkazový formulár · Prihláška
Upozorniť na chybu na PLATON.SK webstránke · Podmienky použitia · Ochrana osobných údajov