? forum_unique_ids_1b.patch
? forum_unique_ids_1c.patch
? template_file_fix_3.patch
? sites/all/modules
? sites/all/themes
? sites/default/settings.php
Index: modules/forum/forum-list.tpl.php
===================================================================
RCS file: /cvs/drupal/drupal/modules/forum/forum-list.tpl.php,v
retrieving revision 1.3
diff -u -p -r1.3 forum-list.tpl.php
--- modules/forum/forum-list.tpl.php	7 Aug 2007 08:39:35 -0000	1.3
+++ modules/forum/forum-list.tpl.php	24 Aug 2007 17:01:54 -0000
@@ -6,7 +6,10 @@
  * Default theme implementation to display a list of forums and containers.
  *
  * Available variables:
- * - $forums: An array of forums and containers to display.
+ * - $forums: An array of forums and containers to display. It is keyed to the
+ *   numeric ID's of all child forums and containers.
+ * - $forum_id: Forum ID for the current forum. Parent to all items within
+ *   the $forums array.
  *
  * Each $forum in $forums contains:
  * - $forum->is_container: Is TRUE if the forum can contain other forums. Is
@@ -28,7 +31,7 @@
  * @see theme_forum_list()
  */
 ?>
-<table>
+<table id="forum-<?php print $tid; ?>">
   <thead>
     <tr>
       <th><?php print t('Forum'); ?></th>
@@ -38,8 +41,8 @@
     </tr>
   </thead>
   <tbody>
-  <?php foreach ($forums as $forum): ?>
-    <tr class="<?php print $forum->zebra; ?>">
+  <?php foreach ($forums as $child_id => $forum): ?>
+    <tr id="forum-list-<?php print $child_id; ?>" class="<?php print $forum->zebra; ?>">
       <td <?php print $forum->is_container ? 'colspan="4" class="container"' : 'class="forum"'; ?>>
         <?php /* Enclose the contents of this cell with X divs, where X is the
                * depth this forum resides at. This will allow us to use CSS
Index: modules/forum/forum-topic-list.tpl.php
===================================================================
RCS file: /cvs/drupal/drupal/modules/forum/forum-topic-list.tpl.php,v
retrieving revision 1.3
diff -u -p -r1.3 forum-topic-list.tpl.php
--- modules/forum/forum-topic-list.tpl.php	7 Aug 2007 08:39:35 -0000	1.3
+++ modules/forum/forum-topic-list.tpl.php	24 Aug 2007 17:01:54 -0000
@@ -10,6 +10,7 @@
  *   information. If you need to change this, @see template_preprocess_forum_topic_list().
  * - $pager: The pager to display beneath the table.
  * - $topics: An array of topics to be displayed.
+ * - $topic_id: Numeric ID for the current forum topic.
  *
  * Each $topic in $topics contains:
  * - $topic->icon: The icon to display.
@@ -32,7 +33,7 @@
  * @see theme_forum_topic_list()
  */
 ?>
-<table>
+<table id="forum-topic-<?php print $topic_id; ?>">
   <thead>
     <tr><?php print $header; ?></tr>
   </thead>
Index: modules/forum/forum.module
===================================================================
RCS file: /cvs/drupal/drupal/modules/forum/forum.module,v
retrieving revision 1.413
diff -u -p -r1.413 forum.module
--- modules/forum/forum.module	12 Aug 2007 15:55:36 -0000	1.413
+++ modules/forum/forum.module	24 Aug 2007 17:01:54 -0000
@@ -728,6 +728,8 @@ function template_preprocess_forum_list(
     }
     $variables['forums'][$id]->last_reply = theme('forum_submitted', $forum->last_post);
   }
+  // Give meaning to $tid for themers. $tid actually stands for term id.
+  $variables['forum_id'] = $variables['tid'];
 }
 
 /**
@@ -785,6 +787,8 @@ function template_preprocess_forum_topic
     // Make this safe for the template
     $variables['topics'] = array();
   }
+  // Give meaning to $tid for themers. $tid actually stands for term id.
+  $variables['topic_id'] = $variables['tid'];
 
   $variables['pager'] = theme('pager', NULL, $variables['forum_per_page'], 0);
 }
