Skip to content

Commit

Permalink
Fixed markup issues and hooks location in moderate.php, search.php, v…
Browse files Browse the repository at this point in the history
…iewforum.php; continuing [1073] and [1089].

git-svn-id: http://punbb.informer.com/svn/punbb/trunk@1092 4dc816b1-62af-4023-b237-cae3452c1eb1
  • Loading branch information
Roman authored and Roman committed Mar 19, 2009
1 parent 074b529 commit 54516dd
Show file tree
Hide file tree
Showing 4 changed files with 34 additions and 19 deletions.
17 changes: 11 additions & 6 deletions moderate.php
Expand Up @@ -1585,13 +1585,18 @@
$forum_page['item_status']['closed'] = 'closed';
}

($hook = get_hook('mr_topic_actions_moved_row_pre_item_title_status_merge')) ? eval($hook) : null;
($hook = get_hook('mr_topic_loop_normal_topic_pre_item_title_status_merge')) ? eval($hook) : null;

if (!empty($forum_page['item_title_status']))
$forum_page['item_title']['status'] = '<span class="item-status">'.sprintf($lang_forum['Item status'], implode(' ', $forum_page['item_title_status'])).'</span>';
$forum_page['item_title']['status'] = '<span class="item-status">'.sprintf($lang_forum['Item status'], implode(', ', $forum_page['item_title_status'])).'</span>';

$forum_page['item_title']['link'] = '<strong><a href="'.forum_link($forum_url['topic'], array($cur_topic['id'], sef_friendly($cur_topic['subject']))).'">'.forum_htmlencode($cur_topic['subject']).'</a></strong>';

($hook = get_hook('mr_topic_loop_normal_topic_pre_item_title_merge')) ? eval($hook) : null;

$forum_page['item_body']['subject']['title'] = '<h3 class="hn"><span class="item-num">'.forum_number_format($forum_page['start_from'] + $forum_page['item_count']).'</span> '.implode(' ', $forum_page['item_title']).'</h3>';


if (empty($forum_page['item_status']))
$forum_page['item_status']['normal'] = 'normal';

Expand All @@ -1607,13 +1612,11 @@
$forum_page['item_status']['new'] = 'new';
}

($hook = get_hook('mr_topic_loop_normal_topic_pre_item_nav_merge')) ? eval($hook) : null;

if (!empty($forum_page['item_nav']))
$forum_page['item_subject']['nav'] = '<span class="item-nav">'.sprintf($lang_forum['Topic navigation'], implode('&#160;&#160;', $forum_page['item_nav'])).'</span>';

($hook = get_hook('mr_topic_actions_moved_row_pre_item_title_merge')) ? eval($hook) : null;

$forum_page['item_body']['subject']['title'] = '<h3 class="hn"><span class="item-num">'.forum_number_format($forum_page['start_from'] + $forum_page['item_count']).'</span> '.implode(' ', $forum_page['item_title']).'</h3>';

// Assemble the Topic subject

$forum_page['item_body']['info']['replies'] = '<li class="info-replies"><strong>'.forum_number_format($cur_topic['num_replies']).'</strong> <span class="label">'.(($cur_topic['num_replies'] == 1) ? $lang_forum['Reply'] : $lang_forum['Replies']).'</span></li>';
Expand All @@ -1629,6 +1632,8 @@

$forum_page['item_body']['subject']['desc'] = '<p>'.implode(' ', $forum_page['item_subject']).'</p>';

($hook = get_hook('mr_topic_actions_row_pre_item_status_merge')) ? eval($hook) : null;

$forum_page['item_style'] = (($forum_page['item_count'] % 2 != 0) ? ' odd' : ' even').(($forum_page['item_count'] == 1) ? ' main-first-item' : '').((!empty($forum_page['item_status'])) ? ' '.implode(' ', $forum_page['item_status']) : '');

($hook = get_hook('mr_topic_actions_row_pre_display')) ? eval($hook) : null;
Expand Down
16 changes: 8 additions & 8 deletions search.php
Expand Up @@ -191,7 +191,7 @@
<div class="main-subhead">
<p class="item-summary forum-noview"><span><?php printf($lang_forum['Search subtitle'], implode(' ', $forum_page['item_header']['subject']), implode(', ', $forum_page['item_header']['info'])) ?></span></p>
</div>
<div class="main-content main-forum forum-noview">
<div class="main-content main-forum forum-forums">
<?php

}
Expand Down Expand Up @@ -334,6 +334,10 @@

$forum_page['item_title']['link'] = '<a href="'.forum_link($forum_url['topic'], array($cur_set['tid'], sef_friendly($cur_set['subject']))).'">'.forum_htmlencode($cur_set['subject']).'</a>';

($hook = get_hook('se_results_topics_row_pre_item_title_merge')) ? eval($hook) : null;

$forum_page['item_body']['subject']['title'] = '<h3 class="hn"><span class="item-num">'.forum_number_format($forum_page['start_from'] + $forum_page['item_count']).'</span> '.implode(' ', $forum_page['item_title']).'</h3>';

$forum_page['item_pages'] = ceil(($cur_set['num_replies'] + 1) / $forum_user['disp_posts']);

if ($forum_page['item_pages'] > 1)
Expand All @@ -348,15 +352,11 @@

($hook = get_hook('se_results_topics_row_pre_item_nav_merge')) ? eval($hook) : null;

if (!empty($forum_page['item_nav']))
$forum_page['item_title']['nav'] = '<span class="item-nav">'.sprintf($lang_forum['Topic navigation'], implode('&#160;&#160;', $forum_page['item_nav'])).'</span>';

($hook = get_hook('se_results_topics_row_pre_item_title_merge')) ? eval($hook) : null;

$forum_page['item_body']['subject']['title'] = '<h3 class="hn"><span class="item-num">'.forum_number_format($forum_page['start_from'] + $forum_page['item_count']).'</span> '.implode(' ', $forum_page['item_title']).'</h3>';

$forum_page['item_subject']['starter'] = '<span class="item-starter">'.sprintf($lang_forum['Topic starter'], '<cite>'.forum_htmlencode($cur_set['poster']).'</cite>').'</span>';

if (!empty($forum_page['item_nav']))
$forum_page['item_subject']['nav'] = '<span class="item-nav">'.sprintf($lang_forum['Topic navigation'], implode('&#160;&#160;', $forum_page['item_nav'])).'</span>';

($hook = get_hook('se_results_topics_row_pre_item_subject_merge')) ? eval($hook) : null;

$forum_page['item_body']['subject']['desc'] = '<p>'.implode(' ', $forum_page['item_subject']).'</p>';
Expand Down
12 changes: 11 additions & 1 deletion style/Oxygen/Oxygen.css
Expand Up @@ -877,7 +877,7 @@ E - INDEX, FORUMS, SEARCH RESULTS, MODERATE FORUMS
.brd .main-content .main-item li.info-views,
.brd .main-content .main-item li.info-replies {
width: 7em;
text-align:center;
text-align: center;
}

.brd .main-content .main-item li.info-forum {
Expand Down Expand Up @@ -921,6 +921,16 @@ E - INDEX, FORUMS, SEARCH RESULTS, MODERATE FORUMS
}

.brd .forum-noview .main-item ul {
width: 27em;
right: -28em;
margin-left: -27em;
}

.brd .forum-forums .main-item {
padding-right: 48em;
}

.brd .forum-forums .main-item ul {
width: 47em;
right: -48em;
margin-left: -47em;
Expand Down
8 changes: 4 additions & 4 deletions viewforum.php
Expand Up @@ -258,6 +258,8 @@

($hook = get_hook('vf_topic_loop_normal_topic_pre_item_title_merge')) ? eval($hook) : null;

$forum_page['item_body']['subject']['title'] = '<h3 class="hn"><span class="item-num">'.forum_number_format($forum_page['start_from'] + $forum_page['item_count']).'</span> '.implode(' ', $forum_page['item_title']).'</h3>';

if (empty($forum_page['item_status']))
$forum_page['item_status']['normal'] = 'normal';

Expand All @@ -278,12 +280,8 @@
if (!empty($forum_page['item_nav']))
$forum_page['item_subject']['nav'] = '<span class="item-nav">'.sprintf($lang_forum['Topic navigation'], implode('&#160;&#160;', $forum_page['item_nav'])).'</span>';

$forum_page['item_body']['subject']['title'] = '<h3 class="hn"><span class="item-num">'.forum_number_format($forum_page['start_from'] + $forum_page['item_count']).'</span> '.implode(' ', $forum_page['item_title']).'</h3>';

// Assemble the Topic subject

($hook = get_hook('vf_topic_loop_normal_topic_pre_item_subject_merge')) ? eval($hook) : null;

$forum_page['item_body']['info']['replies'] = '<li class="info-replies"><strong>'.forum_number_format($cur_topic['num_replies']).'</strong> <span class="label">'.(($cur_topic['num_replies'] == 1) ? $lang_forum['reply'] : $lang_forum['replies']).'</span></li>';

if ($forum_config['o_topic_views'] == '1')
Expand All @@ -292,6 +290,8 @@
$forum_page['item_body']['info']['lastpost'] = '<li class="info-lastpost"><span class="label">'.$lang_forum['Last post'].'</span> <strong><a href="'.forum_link($forum_url['post'], $cur_topic['last_post_id']).'">'.format_time($cur_topic['last_post']).'</a></strong> <cite>'.sprintf($lang_forum['by poster'], forum_htmlencode($cur_topic['last_poster'])).'</cite></li>';
}

($hook = get_hook('vf_row_pre_item_subject_merge')) ? eval($hook) : null;

$forum_page['item_body']['subject']['desc'] = '<p>'.implode(' ', $forum_page['item_subject']).'</p>';

($hook = get_hook('vf_row_pre_item_status_merge')) ? eval($hook) : null;
Expand Down

0 comments on commit 54516dd

Please sign in to comment.