با سلام
در حالت عادی امکان استفاده از تگ {short-story limit="x"} (بصورت محدود شده) در full-story.tpl نیست .
ممنون میشم دوستان راهنمایی کنن چطور میشه {short-story limit="x"} را در full-story.tpl استفاده کرد؟
از فایل /engine/modules/show.short.php قطعه کد زیر را در مسیر /engine/modules/show.full.php خط 1533 کپی کردم ولی ارور داد
if ( preg_match( "#\\{short-story limit=['\"](.+?)['\"]\\}#i", $tpl->copy_template, $matches ) ) { $count= intval($matches[1]); $row['short_story'] = preg_replace( "#<!--TBegin(.+?)<!--TEnd-->#is", "", $row['short_story'] ); $row['short_story'] = preg_replace( "#<!--MBegin(.+?)<!--MEnd-->#is", "", $row['short_story'] ); $row['short_story'] = preg_replace( "'\[attachment=(.*?)\]'si", "", $row['short_story'] ); $row['short_story'] = preg_replace ( "#\[hide\](.+?)\[/hide\]#ims", "", $row['short_story'] ); $row['short_story'] = str_replace( "</p><p>", " ", $row['short_story'] ); $row['short_story'] = strip_tags( $row['short_story'], "<br>" ); $row['short_story'] = trim(str_replace( "<br>", " ", str_replace( "<br />", " ", str_replace( "\n", " ", str_replace( "\r", "", $row['short_story'] ) ) ) )); if( $count AND dle_strlen( $row['short_story'], $config['charset'] ) > $count ) { $row['short_story'] = dle_substr( $row['short_story'], 0, $count, $config['charset'] ); if( ($temp_dmax = dle_strrpos( $row['short_story'], ' ', $config['charset'] )) ) $row['short_story'] = dle_substr( $row['short_story'], 0, $temp_dmax, $config['charset'] ); } $tpl->set( $matches[0], $row['short_story'] ); } }