tpl->layout_exists(1)): ?>
|
forum->options['layout_extended_intro_topics_toggle'], 1); ?>/>
forum->options['layout_extended_intro_topics_toggle'], 0); ?>/>
|
|
|
|
|
|
tpl->layout_exists(3)): ?>
forum->options['layout_qa_intro_topics_toggle'])) WPF()->forum->options['layout_qa_intro_topics_toggle'] = 1;
if(!isset(WPF()->forum->options['layout_qa_intro_topics_count'])) WPF()->forum->options['layout_qa_intro_topics_count'] = 3;
?>
|
forum->options['layout_qa_intro_topics_toggle'], 1); ?>/>
forum->options['layout_qa_intro_topics_toggle'], 0); ?>/>
|
|
|
|
|
|
tpl->layout_exists(4)): ?>
|
forum->options['layout_threaded_intro_topics_toggle'], 1); ?>/>
forum->options['layout_threaded_intro_topics_toggle'], 0); ?>/>
|
|
forum->options['layout_threaded_filter_buttons'], 1); ?>/>
forum->options['layout_threaded_filter_buttons'], 0); ?>/>
|
|
forum->options['layout_threaded_add_topic_button'], 1); ?>/>
forum->options['layout_threaded_add_topic_button'], 0); ?>/>
|
|
|
|
|
|
tpl->layout_exists(1)): ?>
|
post->options['layout_extended_intro_posts_toggle'], 1); ?>/>
post->options['layout_extended_intro_posts_toggle'], 0); ?>/>
|
|
|
|
|
|
|
tpl->layout_exists(3)): ?>
|
tpl->forms['qa_comments_rich_editor'], 1); ?>>
tpl->forms['qa_comments_rich_editor'], 0); ?>>
|
|
tpl->forms['qa_display_answer_editor'], 1); ?>>
tpl->forms['qa_display_answer_editor'], 0); ?>>
|
|
|
|
|
|
|
|
|
post->options['layout_qa_first_post_reply'], 1); ?>>
post->options['layout_qa_first_post_reply'], 0); ?>>
|
|
|
|
|
|
|
tpl->layout_exists(4)): ?>
|
tpl->forms['threaded_reply_rich_editor'], 1); ?>>
tpl->forms['threaded_reply_rich_editor'], 0); ?>>
|
|
|
|
|
|
|
|
|
post->options['layout_threaded_first_post_reply'], 1); ?>>
post->options['layout_threaded_first_post_reply'], 0); ?>>
|
tpl->find_layouts( WPFORO_THEME ) ) : ?>
|
|
|
tpl->layout_exists(3) ){
$string = wpforo_phrase('Your Answer', false, 'default');
}
return $string;
}
add_filter('wpforo_reply_form_head', 'wpforo_classic_reply_form_head', 1, 2);
function wpforo_classic_reply_form_field_title($string, $args){
if( WPF()->tpl->layout_exists(3) ){
$can_answer = true;
if( $args['layout'] === 3 ){
if( wpfval($args, 'topicid') ){
$can_answer = WPF()->topic->can_answer( $args['topicid'] );
}
if( $can_answer ){
$string = preg_replace('|[^\:]+\:|is', wpforo_phrase('Answer to', false, 'default') . ':', $string);
}
}
}
return $string;
}
add_filter('wpforo_reply_form_field_title', 'wpforo_classic_reply_form_field_title', 1, 2);
function wpforo_classic_get_body_class(){
$class = '';
if(isset(WPF()->tpl->options['style'])) $class = 'wpf-' . esc_attr(WPF()->tpl->options['style']);
if(isset(WPF()->current_object['template'])) $class .= ' wpft-' . esc_attr(WPF()->current_object['template']);
return $class;
}
function wpforo_classic_wrap_class(){
echo wpforo_classic_get_body_class();
}
add_action('wpforo_wrap_class', 'wpforo_classic_wrap_class');
function wpforo_classic_body_class($classes){
if( $body_class = wpforo_classic_get_body_class() ) $classes[] = $body_class;
return $classes;
}
add_filter('body_class', 'wpforo_classic_body_class');
function wpforo_login_status_class(){
echo ( WPF()->current_userid ) ? ' wpf-auth' : ' wpf-guest';
}
add_action('wpforo_wrap_class', 'wpforo_login_status_class');
function wpforo_forum_layout_editors( $settings, $editor ){
if( $editor == 'post' && 4 == wpfval(WPF()->current_object, 'layout')){
$settings['tinymce']['toolbar1'] = 'fontsizeselect,bold,italic,underline,forecolor,bullist,numlist,alignleft,aligncenter,alignright,link,unlink,blockquote,pre,wpf_spoil,pastetext,source_code,emoticons';
$settings['editor_height'] = 100;
}
return $settings;
}
add_filter('wpforo_editor_settings', 'wpforo_forum_layout_editors', 1, 2);