Bakı Uşaq Teatrı hər ayın bir gününü Milli geyim günü kimi qeyd etmək qərarına gəlib. AİA.AZ
17-04-2016, 21:42
Deputatla bağlı şok iddia: “Şahlara məxsus malikanə, Yaponiyadan ağ mərmər…” – FOTO
Sumqayıtın mədəniyyət müəssisələrində qəhrəmanlıq mövzusunda silsilə tədbirlər keçirilib
", " ", $newscontent['short_story'] );
$newscontent['short_story'] = strip_tags( $newscontent['short_story'], "
" );
$newscontent['short_story'] = trim(str_replace( "
", " ", str_replace( "
", " ", str_replace( "\n", " ", str_replace( "\r", "", $newscontent['short_story'] ) ) ) ));
if( $count AND dle_strlen( $newscontent['short_story'], $config['charset'] ) > $count ) {
$newscontent['short_story'] = dle_substr( $newscontent['short_story'], 0, $count, $config['charset'] );
if( ($temp_dmax = dle_strrpos( $newscontent['short_story'], ' ', $config['charset'] )) ) $newscontent['short_story'] = dle_substr( $newscontent['short_story'], 0, $temp_dmax, $config['charset'] );
}
$tpl12->set( $matches[0], $newscontent['short_story'] );
} else $tpl12->set( '{text}', $newscontent['short_story'] );
/*Îáðàáîòêà òåêñòà êîíåö*/
/*Îáðàáîòêà äîïîëíèòåëüíûõ ïîëåé íà÷àëî*/
if( $xfound ) {
$xfieldsdata = xfieldsdataload( $newscontent['xfields'] );
foreach ( $xfields as $value ) {
$preg_safe_name = preg_quote( $value[0], "'" );
if ( $value[6] AND !empty( $xfieldsdata[$value[0]] ) ) {
$temp_array = explode( ",", $xfieldsdata[$value[0]] );
$value3 = array();
foreach ($temp_array as $value2) {
$value2 = trim($value2);
$value2 = str_replace("'", "'", $value2);
if( $config['allow_alt_url'] == "yes" ) $value3[] = "" . $value2 . ""; else $value3[] = "" . $value2 . "";
}
$xfieldsdata[$value[0]] = implode(", ", $value3);
unset($temp_array);
unset($value2);
unset($value3);
}
if( empty( $xfieldsdata[$value[0]] ) ) {
$tpl12->copy_template = preg_replace( "'\\[xfgiven_{$preg_safe_name}\\](.*?)\\[/xfgiven_{$preg_safe_name}\\]'is", "", $tpl12->copy_template );
$tpl12->copy_template = str_replace( "[xfnotgiven_{$preg_safe_name}]", "", $tpl12->copy_template );
$tpl12->copy_template = str_replace( "[/xfnotgiven_{$preg_safe_name}]", "", $tpl12->copy_template );
} else {
$tpl12->copy_template = preg_replace( "'\\[xfnotgiven_{$preg_safe_name}\\](.*?)\\[/xfnotgiven_{$preg_safe_name}\\]'is", "", $tpl12->copy_template );
$tpl12->copy_template = str_replace( "[xfgiven_{$preg_safe_name}]", "", $tpl12->copy_template );
$tpl12->copy_template = str_replace( "[/xfgiven_{$preg_safe_name}]", "", $tpl12->copy_template );
}
$tpl12->copy_template = str_replace( "", stripslashes( $xfieldsdata[$value[0]] ), $tpl12->copy_template );
}
}
/*îáðàáîòêà äîïîëíèòåëüíûõ ïîëåé êîíåö*/
/*Îáðàáîòêà äàòû íà÷àëî*/
$newscontent['date'] = strtotime($newscontent['date']);
if( date( 'Ymd', $newscontent['date'] ) == date( 'Ymd', $_TIME ) )
$tpl12->set( '{date}', langdate( "H:i", $newscontent['date'] ) );
elseif( date( 'Ymd', $newscontent['date'] ) == date( 'Ymd', ($_TIME - 86400) ) )
$tpl12->set( '{date}', langdate( "H:i", $newscontent['date'] ) );
else
$tpl12->set( '{date}', langdate( "H:i", $newscontent['date'] ) );
/*Îáðàáîòêà êàòåãîðèè íà÷àëî*/
if( ! $newscontent['category'] ) {
$my_cat = "---";
$my_cat_link = "---";
} else {
$my_cat = array ();
$my_cat_link = array ();
$cat_list = explode( ',', $newscontent['category'] );
if( count( $cat_list ) == 1 ) {
$my_cat[] = $cat_info[$cat_list[0]]['name'];
$my_cat_link = get_categories( $cat_list[0] );
} else {
foreach ( $cat_list as $element ) {
if( $element ) {
$my_cat[] = $cat_info[$element]['name'];
if( $config['allow_alt_url'] == "yes" ) $my_cat_link[] = "{$cat_info[$element]['name']}";
else $my_cat_link[] = "{$cat_info[$element]['name']}";
}
}
$my_cat_link = implode( ', ', $my_cat_link );
}
$my_cat = implode( ', ', $my_cat );
}
/*Îáðàáîòêà êàòåãîðèé êîíåö*/
$tpl12->set( '{full-link}', "$full_link" );
$tpl12->set( '[full-link]', "" );
$tpl12->set( '[/full-link]', "" );
$tpl12->set("{title}", htmlspecialchars( strip_tags( stripslashes( $newscontent['title'] ) ), ENT_QUOTES, $config['charset'] ) );
$tpl12->set("{category}", $my_cat_link);
$tpl12->compile( 'news_select' );
}
$tpl1->set("{news_select}", $tpl12->result['news_select']); unset($tpl12);
$tpl1->compile( 'lastnews' );
}
create_cache( "lastnews", $tpl1->result['lastnews'], $config['skin'], true );
}
echo $tpl1->result['lastnews'];
?>
























