# , $params[?] ^form:fields.foreach[field;value]{ ^if($field eq "y" || $field eq "m" || $field eq "d" || $field eq "act" || $field eq "r_a" || $field eq "go" || $field eq "query"){ }{ $params[${params}${field}=${value}&] } } $params[^params.mid(0; ^params.length[]-1)] ^if($params eq ""){ $params[index.html?id=1] } # $date_now[^date::now[]] ^switch[$form:id]{ #News ^case[1]{$rub[and razdel=1] } #Author materials ^case[2]{ ^if(def $form:r_id){ $rub[and razdel='2' and rub_id='$form:r_id'] }{ $rub[and razdel='2'] } } #Anons ^case[3]{$rub[and razdel=1] } #Economics ^case[6]{$rub[and rub_id='3' and razdel=1] } #Society ^case[7]{$rub[and rub_id='4' and razdel=1] } #Events ^case[8]{$rub[and rub_id='5' and razdel=1] } #Hot topic ^case[10]{$rub[and razdel=4] } #AGENCY ^case[11]{$rub[and razdel=1] } #REGION ^case[12]{$rub[and razdel=1] } #PERSONALITIES ^case[13]{$rub[and razdel=1] } #Sport ^case[19]{$rub[and rub_id='15' and razdel=1] } # ^case[23]{$rub[and rub_id='23' and razdel=1] } # ^case[26]{$rub[and (rub_id='1' and razdel=1)] } # ^case[27]{$rub[and (rub_id='3' and razdel=1)] } # ^case[28]{$rub[and (rub_id='4' and razdel=1)] } # ^case[29]{$rub[and (rub_id='5' and razdel=1)] } ^case[DEFAULT]{$rub[and razdel=1] } } ^if(def $form:y && def $form:m){ ^connect[$connect_string]{ $dates[^table::sql{select distinct date from news where date BETWEEN '${form:y}-${form:m}-00' and '${form:y}-${form:m}-31 23:59:59' $rub order by date asc}] } }{ ^connect[$connect_string]{ $dates[^table::sql{select distinct date from news where date BETWEEN '${date_now.year}-${date_now.month}-00' and '${date_now.year}-${date_now.month}-31 23:59:59' $rub order by date asc}] } } ^if($dates){ $days_of_files[^hash::create[]] ^dates.menu{ $new_date[^date::create[$dates.date]] $str[$new_date.day] $days_of_files.$str[1] } } ^if(def $days_of_files){ }{ $days_of_files[^hash::create[]] $days_of_files.0[1] } $date_user[ $.day(^form:d.int(0)) $.month(^form:m.int($date_now.month)) $.year(^form:y.int($date_now.year)) $.start_y(2003) $.start_m(9) ] ^use[calendar.p] $c[^calendar::init[$date_user;$days_of_files;$params]] #end of calendar ^if(def $form:d){ ^if(def $form:y){ $pre[and date between ] $date['${form:y}-] ^if(def $form:m){ $date[${date}${form:m}-] }{ $date[${date}00-] } $date[${pre}${date}${form:d} 00:00:00' and ${date}${form:d} 23:59:59'] } }{ ^if(def $form:y){ $date[and date between '${form:y}-] ^if(def $form:m){ $date[${date}${form:m}-00'] $next(^form:m.int(0) + 1) }{ $date[${date}01-00'] $next(02) } $date[$date and '${form:y}-${next}-00'] } } # - ^if(def $form:y){ }{ $date[] $lim[limit $offset,30] } $month_names[ $.1[] $.2[] $.3[] $.4[] $.5[] $.6[] $.7[] $.8[] $.9[] $.10[] $.11[] $.12[] ] ^if(def $form:vote && def $form:answer && def $form:poll){ $poll[$form:poll] ^if($cookie:weekpoll ne $poll){ ^connect[$connect_string]{ ^void:sql{update answers set votes=votes+1 where id=$form:answer} } $cookie:weekpoll[ $.value[$poll] $.expires(7) ] } } $now[^date::now[]] ^connect[$connect_string]{ $pf[^table::sql{select id, name from rubrika where (r_id=2 and id=7) order by id asc}] ^if(^form:pid.int(0) > 0 && ^form:r_id.int(0) == 0 && ^form:id.int(0) == 1){ $leftnews[^table::sql{select id, date, head from news where date <= NOW() and ^if($form:id){ razdel='$form:id'}{razdel=1} $date order by date desc LIMIT 10}] $leftsotd[^table::sql{select id, date, head, anons, pic_body from news where date <= NOW() and razdel=4 order by date desc limit 1}] }{ ^if(^form:r_id.int(0) > 0){ $am[^table::sql{select id, name from rubrika where (r_id=2 and id = ^form:r_id.int(0))}] $maxlim(9) }{ $am[^table::sql{select id, name from rubrika where (r_id=2 and id > 7) order by id asc}] $maxlim(3) } } # $hot[^table::sql{select id, date, head from news where (date <= NOW() and razdel=1) and hot=1 order by date desc LIMIT 10}] $review[^table::sql{select id, date, head from news where date <= NOW() and razdel=3 order by date desc LIMIT 3}] # $am3[^table::sql{select id, head from news where razdel=2 and rub_id=8 order by id desc limit 3}] # $am2[^table::sql{select id, head from news where razdel=2 and rub_id=9 order by id desc limit 3}] # $am4[^table::sql{select id, head from news where razdel=2 and rub_id=10 order by id desc limit 3}] # $am5[^table::sql{select id, head from news where razdel=2 and rub_id=13 order by id desc limit 3}] # $am6[^table::sql{select id, head from news where razdel=2 and rub_id=14 order by id desc limit 3}] # $anons[^table::sql{select id, anons from anons where date='^now.sql-string[]' order by id asc}] # $informer[^table::sql{select id, link, alt, pic from informer order by id asc}] $banners[^table::sql{select id, razdel from banners order by id desc}] ^if($banners){ $id(^form:id.int(1)) ^banners.menu{ $parts[^banners.razdel.split[,;lv]] ^if(^parts.locate[piece;$id]){ $ids[$ids id=$banners.id or ] } } ^if($ids ne ""){ $ids[^ids.mid(1;^ids.length[]-5)] $ids[($ids)] $bannerstop[^table::sql{select id, name, link, logo, type, width, height from banners where type=1 and ( views < max and (date >= now() or date = '0000-00-00') ) and $ids order by id desc}] $banners468[^table::sql{select id, name, link, logo, type, width, height from banners where type=2 and ( views < max and (date >= now() or date = '0000-00-00') ) and $ids order by id desc limit 1}] $bannersown[^table::sql{select id, name, link, logo, type, width, height from banners where type=4 and ( views < max and (date >= now() or date = '0000-00-00') ) and $ids order by id desc limit 1}] $bannersbot[^table::sql{select id, name, link, logo, type, width, height from banners where type=3 and ( views < max and (date >= now() or date = '0000-00-00') ) and $ids order by id desc}] $bannersright[^table::sql{select id, name, link, logo, type, width, height from banners where type=5 and ( views < max and (date >= now() or date = '0000-00-00') ) and $ids order by id desc}] } } } ^try{ # $hot[^table::load[nameless;http://www.rosbalt.ru/backend/topnews.txt]] # $hot[^table::load[nameless;topnews.txt]] }{ $exception.handled(true) }
:

e-mail:

^connect[$connect_string]{ $poll[^table::sql{select id, question, status, dt_started from polls where status='active' order by id desc limit 1}] ^if($poll){ $answers[^table::sql{select id, answer, votes from answers where poll_id=$poll.id order by id asc}] ^if($answers){ $total(0) ^answers.menu{ $total(^eval($total + ^answers.votes.int(0))) $total2($total) } ^if($cookie:weekpoll ne $poll.id){ }{ }
$poll.question
^answers.menu{ $answers.answer }[
]
^answers.menu{ $answers.answer $tmp(^eval(^answers.votes.int(0)*100)) $tmp2(^eval(^answers.votes.int(0)*100))
$answers.votes (^eval($tmp2 / $total)[%.1f]%) }[
]
: $total2
} } }
 ^;
^c.calendar[$params] << ^; ^; ^;>>
^connect[$connect_string]{
,
:

^int:sql{select today from config}[$.default{0}]

^int:sql{select total from config}[$.default{0}] }

Rambler's Top100 Rambler's Top100   - logoSlovo.RU
 Rambler's Top100 .
^if(def $form:act){ ^switch[$form:act]{ ^case[arc]{ ^use[archive.p] ^content[$request:query] } ^case[srch]{^use[srch.p] ^content[$request:query] } } }{ ^switch[$form:id]{ #Interview ^case[1]{^use[am.p] ^content[$request:query] } #Reportazh ^case[2]{^use[am2.p] ^content[$request:query] } #Statiya ^case[3]{^use[am3.p] ^content[$request:query] } # ^case[4]{^use[am4.p] ^content[$request:query] } # ^case[5]{^use[am5.p] ^content[$request:query] } # ^case[6]{^use[am6.p] ^content[$request:query] } # ^case[7]{^use[am7.p] ^content[$request:query] } # ^case[8]{^use[am8.p] ^content[$request:query] } #- ^case[9]{^use[am9.p] ^content[$request:query] } #Hot topic ^case[10]{^use[hot.p] ^content[$request:query] } #AGENCY ^case[11]{^use[agency.p] ^content[$request:query] } #REGION ^case[12]{^use[region.p] ^content[$request:query] } #PERSONALITIES ^case[13]{^use[person.p] ^content[$request:query] } #CONTACTS ^case[14]{^use[cont.p] ^content[$request:query] } #LINKS ^case[15]{^use[links.p] ^content[$request:query] } #Guest book ^case[16]{^use[gb.p] ^content[$request:query] } #Jurist ^case[17]{^use[jur.p] ^content[$request:query] } #Sport ^case[19]{^use[sport.p] ^content[$request:query] } #BusinessCatalog ^case[20]{^use[bk.p] ^content[$request:query] } #Search ^case[21]{^use[srch.p] ^content[$request:query] } #Subscribe ^case[22]{^use[subscribe.p] ^content[$request:query] } #Polls ^case[23]{^use[poll.p] ^content[$request:query] } #Photoreports ^case[25]{^use[photo.p] ^content[$request:query] } # ^case[26]{^use[eparh1.p] ^content[$request:query] } # { ^case[27]{^use[eparh2.p] ^content[$request:query] } # { ^case[28]{^use[eparh3.p] ^content[$request:query] } # { ^case[29]{^use[eparh4.p] ^content[$request:query] } ^case[DEFAULT]{^use[news.p] ^content[$request:query] } #Guest book2 ^case[30]{^use[gb2.p] ^content[$request:query] } #comercial ^case[33]{^use[com.p] ^content[$request:query] } } }

^connect[$connect_string]{ $report[^table::sql{select id, name, date from reports where status='active' order by date desc limit 1}] ^if($report){ $photos[^table::sql{select id, small, text from photo where reportID=$report.id order by id asc}] ^if($photos){ } $photos.text
$report.name
} } ^if($am){ ^am.menu{ ^connect[$connect_string]{ $heads[^table::sql{select id, head, icon, date from news where razdel=2 and rub_id=$am.id order by date desc limit $maxlim}] } }[
] } ^if($leftsotdd){
^leftsotd.menu{ $date[^date::create[$leftsotd.date]] ^if($leftsotd.pic_body ne "" && -f "$leftsotd.pic_body"){ ^try{ ^use[images.p] # $ext[^file:justext[$leftsotd.pic_body]] # $nam[^file:justname[$leftsotd.pic_body]] # $image_name[${nam}.$ext] $image_name[^file:basename[$leftsotd.pic_body]] ^if(-f "/pics/small/$image_name"){ }{ # $foto[/pics/small/$image_name] # ^form:foto1.save[binary;/$foto] $source_path[/pics/body/] $destination_path[/pics/small/] # $destination_path2[/shop/images/goods/previews/] $check[^image::measure[$leftsotd.pic_body]] ^if($check.width >= $check.height){ $resized[x] }{ $resized[y] } $status[^images:resize[ $.source_path[$source_path] $.destination_path[$destination_path] $.image_name[$image_name] ^if($resized eq "x"){ $.x_size(64) }{ $.y_size(64) } $.quality[85] ]] ^if($status){$status} $result } }{ ^if($exception.type eq image.format){ $exception.handled(true) } } } ^if(-f "/pics/small/$image_name"){ $foto[^image::measure[/pics/small/$image_name]] ^foto.html[ $.align[left] $.hspace[5] $.vspace[5] ] } ^check[$date.hour]:^check[$date.minute] $leftsotd.head # ^if(^leftsotd.head.length[] <= 30 || $photo.height > 40){
} }[

]
}


^connect[$connect_string]{ $trisome[^table::sql{select id, head, anons, icon, date from news where razdel=2 and rub_id=34 order by date desc limit 0,1}] } $trisome.head

^untaint{^if(^trisome.anons.mid(0;5) eq " "){^trisome.anons.mid(6)}{$trisome.anons}}
^connect[$connect_string]{ $trisome[^table::sql{select id, head, anons, icon, date from news where razdel=2 and rub_id=34 order by date desc limit 1,1}] } $trisome.head

^untaint{^if(^trisome.anons.mid(0;5) eq " "){^trisome.anons.mid(6)}{$trisome.anons}}
^connect[$connect_string]{ $trisome[^table::sql{select id, head, anons, icon, date from news where razdel=2 and rub_id=34 order by date desc limit 2,1}] } $trisome.head

^untaint{^if(^trisome.anons.mid(0;5) eq " "){^trisome.anons.mid(6)}{$trisome.anons}}

^connect[$connect_string]{ $lastone[^table::sql{select id, head, anons, icon, date from news where razdel=2 and rub_id=31 order by date desc limit 0,1}] } $lastone.head

^untaint{^if(^lastone.anons.mid(0;5) eq " "){^lastone.anons.mid(6)}{$lastone.anons}}

^connect[$connect_string]{ $lastone[^table::sql{select id, head, anons, icon, date from news where razdel=2 and rub_id=11 order by date desc limit 0,1}] } $lastone.head

^untaint{^if(^lastone.anons.mid(0;5) eq " "){^lastone.anons.mid(6)}{$lastone.anons}}

^connect[$connect_string]{ $lastone[^table::sql{select id, head, anons, icon, date from news where razdel=2 and rub_id=10 and topic_id!=999 order by date desc limit 0,1}] } $lastone.head

^untaint{^if(^lastone.anons.mid(0;5) eq " "){^lastone.anons.mid(6)}{$lastone.anons}}






#
# ^if($pf){ # ^pf.menu{ # ^connect[$connect_string]{ # $heads[^table::sql{select id, head, icon, date from news where razdel=2 and rub_id=35 order by date desc limit 0,1}] # } # ^if($heads){ # #
# ^heads.menu{ # $dat[^date::create[$heads.date]] # ^if($heads.icon ne ""){ # $photo[^image::measure[$heads.icon]] # ^photo.html[ # $.align[default] # ] # } #
$heads.head
# } # } # } # } # #


^connect[$connect_string]{ $heads[^table::sql{select id, head, icon, date from news where razdel=2 and rub_id=35 order by date desc limit 0,1}] } # $photo[^image::measure[$heads.icon]] # ^photo.html[ # $.align[default] # ]
$heads.head

^connect[$connect_string]{ $inf[^table::sql{select id, link, alt, pic from informer order by id asc limit 2,11}] } ^if($inf){ ^inf.menu{ ^if($inf.alt ne ""){
^if($inf.pic ne ""){ } $inf.alt } } }
www.pravoslavie-nord.ru .
Copyright "-" 2007
CodeIgniter