Hello,
I have created a content type with the cck tablefield in it. I have successfully created content of this node type and the tables look as they should. But when I visit the edit page all expandable menus are plain text (not clickable), so I can't open them to change the settings for the node.
When I create new content of this content type, or editing a content type without the tablefield, all menus works good. So the problem only appears when editing an existing node with the tablefield.

CommentFileSizeAuthor
#2 tablefield.627432.2.patch.txt525 byteskevin hankens

Comments

JockeL’s picture

This problem seems to appear only when the "Number of values" option on the Manage fields page is set to Unlimited.

kevin hankens’s picture

StatusFileSize
new525 bytes

Hey, thanks for the report. I haven't been able to reproduce, but I have a patch that might help. It just removes the collapsibility of the fieldset. Can you try applying it and see if you can see the table fields?

fw_crocodile’s picture

Version: 6.x-1.0-beta2 » 6.x-1.1
Priority: Normal » Critical

Hi,

I can confirm that the problem persist.

The problem appear when the "Number of values" option on the Manage fields page is different from 1. It seems the problem appear when more than one table form is used.

If you see at code of the generated page, with "Number of values" set to 1:

<fieldset id="node-tablefield-0" class="node-tablefield"><legend>...............</fieldset>

while with "Number of values" set to 2:

<table id="field_prova_values" class="content-multiple-table sticky-enabled">
<thead><tr><th colspan="2">Tabelle Classifica: </th><th>Ordine</th> </tr></thead>
<tbody>
<tr class="draggable odd"><td class="content-multiple-drag"></td><td><fieldset id="node-tablefield-0" class="node-tablefield"><legend>........................
</table>

So there is something different on the "outside" container of the form's section regarding tablefield module that is different when you change the number of values settings.

fw_crocodile’s picture

may be, just adding a fieldset container would be sufficient to eliminate the problem.

fw_crocodile’s picture

More details:

the problem is not only related to "Number of values" option. You have to have "Number of values" option set to a value different from "1" AND a table with at least one field (not zero row and columns).

fw_crocodile’s picture

I've done some more inquiry.

I think the problem is related to the markup of the form. But I didn't found how to resolv.

But I've found another problem. It seems that there is something wrong with the <tr> tag. The closing tag is used instead of the opening one.
I've resolved the problem incrementing the index.

    $element['tablefield']['break' . ($i + 1)] = array(
      '#type' => 'markup',
      '#value' => '</tr>',
    );
  }
  $element['tablefield']['break' . ($i + 1)] = array(
    '#type' => 'markup',
    '#value' => '</table>',
  );

But this isn't enough to resolve the collapse problem.

kevin hankens’s picture

Cool, thanks for all of the research on this one. I'm pretty slammed at the moment, but I'll try to do some testing soon!

kevin hankens’s picture

Out of curiosity, which browser are you using? Also, are you aggregating CSS and Javascript files?

I ran into an issue one day where I was on a site with a lot of modules and there was a strange JS error occurring. Aggregating CSS and JS files in Site Configuration -> Performance fixed it.

fw_crocodile’s picture

Hi,

I'm using iceweasel (say firefox on debian) and konqueror. The same behaviour appear on both browser. Both CSS and JS optimization are turned on.

fw_crocodile’s picture

I definitely think this is related to markup and js. But I really could not found which is the problem. This happen in multiple situation related to number and type of fields you've added with the cck module to the node type. Unfortunatly this make to module unusable.

kevin hankens’s picture

I am unable to reproduce. Are you certain that you are using the latest version 6.x-1.1?

Thanks!

fw_crocodile’s picture

Hi,

yes I am, but i'm using some other modules too, may be some conflict between modules. I've some modules to be updated, I will update them and then post some more details on the configuration I'm using.

fw_crocodile’s picture

Hi,

I finally found where the problem was. It's not directly related to your module.

The "conflict" was with JQuery Update 6.x-2.x-dev that I need for a lightbox. I should have thinked about JQuery Update first. I will change the lightbox and remove the dependecie.

So it's definitely about js.

In the mean time, exploring your code, some idea to improve a little your module came to my mind, I will try to transform the idea in some code and eventually propose some little code change in a feature request.

Bye
Anselmo

vthirteen’s picture

same problem here. the last version of jquery (1.3, the one in the most recent JQuery Update 6.x-2.x-dev ) is used by a bunch of modules and wysiwyg editors...

tchopshop’s picture

Yes, I'm using the latest version of jquery and update and it disables most of the javascript on my page. I really would love to use this module!

kevin hankens’s picture

In my, sparse, freetime, I've only been focusing on 7.x-2.x. Can someone suggest a patch that fixes this?

Thanks!

ndf’s picture

jquery_update 6.x-2.x-dev (2011-Apr-20) solves the problem with hanging js.
(At least with ckeditor & superfish menu)

lolandese’s picture

Issue summary: View changes
Status: Active » Fixed

As for the latest comment this seems to be fixed with a newer JQuery version. Reopen if it still occurs.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.