- πΈπ°Slovakia gresko8
+1 RTBC
Using multiple expanders per page on one of our sites.
Great module, but I am having a bit of a problem with using more than 1 field with the expander in my View. Here is the scenario:
- Content view
- 4 fields - title, body, standards, assessment
- Standards & Assessment I need to use the expander field for. Both are long text fields in a content type, similar to how the body field would be setup
When I make one of the fields (Standards) into an Expander, the first one shows the text ("Standards Overview") to expand down fine, and the functionality is there, meaning that the text expands. However if I try to make the 2nd field (Assessment) into an expander as well, it's Expand Text shows "Standards Overview" as well BUT it does show the text for assessment.
So essentially it looks like this
Unexpanded:
Standards Overview
Standards Overview
Expanded:
Standards Overview
Standards Overview text
Standards Overview
Assessment text
I'm not a programmer but I poked around in the HTML being output and it looks like around line 120, where it has this:
'#prefix' => '<div class="field-expander field-expander-' . $delta . '">',
the resulting output of more than one expander field shares the same number, so they both end up with "field-expander-0" as their class name. Not sure if that has anything to do with the duplicated titles but I did notice that.
Any help that you can offer for this would be greatly appreciated!
Thanks!
Not all content is available!
It's likely this issue predates Contrib.social: some issue and comment data are missing.
+1 RTBC
Using multiple expanders per page on one of our sites.