Index: term_permissions.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/term_permissions/term_permissions.module,v
retrieving revision 1.3
diff -u -r1.3 term_permissions.module
--- term_permissions.module	12 Mar 2009 14:59:51 -0000	1.3
+++ term_permissions.module	12 Mar 2009 16:01:19 -0000
@@ -25,15 +25,31 @@
     $form['identification']['#weight'] = -15;
     $form['advanced']['#weight'] = -10;
 
+    // TODO: Looks like IE7 broke tables in collapsed fieldsets in a point
+    // upgrade. Default the fieldset to be open and collapse it after the
+    // page load instead.
+    // http://drupal.org/node/247957
     $form['access'] = array(
       '#type' => 'fieldset',
       '#title' => t('Permissions'),
       '#description' => t('To limit selection of this term by user or roles, add users or roles to the following lists. Leave empty to allow selection by all users.'),
       '#collapsible' => TRUE,
-      '#collapsed' => TRUE,
+      '#collapsed' => (strpos($_SERVER['HTTP_USER_AGENT'],'MSIE 7.0') !== FALSE) ? FALSE : TRUE,
+      '#attributes' => array('id' => 'fieldset_term_access'),
       '#weight' => -5,
       '#tree' => TRUE,
     );
+    if (strpos($_SERVER['HTTP_USER_AGENT'],'MSIE 7.0') !== FALSE) {
+      // collapse the fieldset when the page is ready and the toggle works.
+      $js_code = "
+        if (Drupal.jsEnabled) {
+          $(document).ready(function() {
+            $('#fieldset_term_access').addClass('collapsed');
+          });
+        };
+      ";
+      drupal_add_js($js_code,'inline','footer');
+    }
     // Note that the autocomplete widget will only enable for users with the
     // 'access profiles' permission. Other users will have to specify the name
     // manually.
