Generowanie listy kwadransów w smartach


<select name="time">
!{section name=ih start=0 loop=24 step=1}!
!{section name=im start=0 loop=60 step=15}!
<option>!{$smarty.section.ih.index|string_format:"%02d"}!:!{$smarty.section.im.index|string_format:"%02d"}!</option>
!{/section}!
!{/section}!
</select>

Generowanie listy kwadransów w smartach

Zmiana wartości opcji selecta

Zmiana wartości opcji selecta


$('#right table td input[name=imie]').parent().parent().parent().css({'display':'none'});
$('#right table .teh').parent().parent().parent().parent().css({'display':'none'});
$('#right table td select[name=stanowisko] option:eq(0)').replaceWith("Zamiana wartości text");
$('#right table td select[name=stanowisko]').parent().prev().html('Zmiana tytułu labela nad selectem taki');
$('#right table td select[name=stanowisko]').val('0');

Zapytanie do bazy z wykorzystaniem funkcji NOW()

select * from table where t_add_date < NOW()-'5 MONTH'::interval
select * from table where t_add_date < NOW()+'5 MONTH'::interval
select * from table where t_add_date < NOW()-'1 DAY'::interval
select * from table where t_add_date < NOW()-'2 DAYS'::interval
select * from table where t_add_date < NOW()-'1 DAY'::interval
select * from table where t_add_date < NOW()-'5 MINUTES'::interval
select * from table where t_add_date < NOW()-'3 HOURS'::interval