I know people have posted this before, but I can't solve this problem based on the posts I've seen:

I have installed flatforum on my Drupal 4.7 Installation, using the Sharepoint-like Theme, which supposedly uses PHPTemplate. I've put the styles from flatforum at the end of the styles.css file in the Sharepoint-like Theme folder, added the node-forum.tpl.php to the Sharepoint-like Theme folder, and added the contents of template.php from flatforum to the template.php file in the Sharepoint-like Theme folder, and enabled the flatforum module on the modules admin page.

However, the Forum doesn't change it's look, and the source for the forum page doesn't seem to contain any of the css ids or classes added to the style.css file from the flatforum stylesheet.

What do I do?

Here are the contents of the template.php file now:

function sharepoint_like_regions() {
  return array(
      'left' => t('left sidebar'),
      'content' => t('content'),
      'header' => t('header'),
      'footer' => t('footer')
  );
}
function phptemplate_menu_tree($pid = 1) {
  if ($tree = menu_tree($pid)) {
    $output .= "\n<ul>\n"; 
    if (function_exists('base_path')) {
      $base_path = base_path();
    }
    $url = $base_path;    
    if ($pid == 1) {
      $output .= "<li><a href=\"" . $url . "\">home</a></li>";
    };
    $output .= $tree; 
    $output .= "\n</ul>\n"; 
    return $output;
  }
}
function phptemplate_menu_item($mid, $children = '', $leaf = TRUE) {
  //return '<li class="'. ($leaf ? 'leaf' : ($children ? 'expanded' : 'collapsed')) .'">'. menu_item_link($mid) . $children ."</li>\n";
  return '<li>'. menu_item_link($mid) . $children ."</li>\n";
}

$nid));
}
$is_forum = ($node && $node->type == 'forum');
_is_forum($is_forum);
}
if ($is_forum) {
switch ($hook) {
case 'comment' :
$variables['template_file'] = 'node-forum';
$variables['row_class'] = _row_class();
$variables['name'] = $vars['author'];
$variables['userid'] = $vars['comment']->uid;
$joined = module_invoke('flatforum', 'get_created', $vars['comment']->uid);
$variables['joined'] = $joined ? format_date($joined, 'custom', 'Y-m-d') : '';
$posts = module_invoke('flatforum', 'get', $vars['comment']->uid);
$variables['posts'] = $posts ? $posts : 0;
$variables['submitted'] = format_date($vars['comment']->timestamp);
$subject = $vars['comment']->subject;
$variables['title'] = empty($subject) ? '&nbsp' : $subject;
$variables['content'] = $vars['comment']->comment;
$variables['links'] = empty($vars['links']) ? '&nbsp' : $vars['links'];
break;
case 'node' :
$variables['row_class'] = _row_class();
$variables['userid']=$vars['node']->uid;
$joined = module_invoke('flatforum', 'get_created', $vars['node']->uid);
$variables['joined'] = $joined ? format_date($joined, 'custom', 'Y-m-d') : '';
$posts = module_invoke('flatforum', 'get', $vars['node']->uid);
$variables['posts'] = $posts ? $posts : 0;
$variables['title'] = empty($vars['title']) ? '&nbsp' : $vars['title'];
$variables['content'] = $vars['node']->body;
$variables['links'] = empty($vars['links']) ? '&nbsp' : $vars['links'];
break;
}
}
return $variables;
}
function _row_class() {
static $forum_row = TRUE;
$forum_row = !$forum_row;
return $forum_row ? 'odd' : 'even';
}
function _is_forum($arg = NULL) {
static $is_forum = FALSE;
if ($arg) {
$is_forum = $arg;
}
return $is_forum;
}

Comments

spazfox’s picture

I have the exact same issue using the Slash theme. Followed installation instructions exactly, but there is no effect on the theming of forums.

michelle’s picture

Status: Active » Closed (fixed)

Just tidying up.

Michelle

somatics’s picture

So no one answers this item, and the solution after a while of no answer is to close it?

What's the solution to this problem?

michelle’s picture

I closed it because a) Flatforum is dead b) 4.7 is unsupported. c) Posters of 2.5 year old support requests have generally moved on. You can set it active again if you want but the odds of anyone ever answering it are pretty slim.

Michelle