Accordian Question...

User 283347 Photo


Registered User
388 posts

Hello All...

Within the components for the Bootstrap Framework, there is "Basic Accordion-Multi-expand" accordion. I would like to use it, but I would like it to be all closed (or collapsed) to begin with.
I have tried to change "aria Exanded:true" to "false", but that did not work. I also tried changing "data toggle: collapse" to 'data toggle: show' and Aria Controls:collapseOne to showOne and a few other things...but no go.

Can anyone show me (or tell me) what everything needs to look like so they will be collapsed to begin with?
I gained a little knowledge from here... https://getbootstrap.com/docs/4.0/components/collapse/ but no success.

Thanks,
Mark
User 2273654 Photo


Registered User
754 posts

I tried loading one into one of my spare pgs of my current project spent about 10 minutes on it so far. I'm not on the bootstrap though using the F6. They had 3 of the accordian ones the one I selected said basic accordian all closed worked fine and it closes up. The other one I could not get all of them to ever close up. So if the basic one all closed would work for you that would be the one to use and it seems to be the same as the others just is the one that starts closed and will all close up.
My CC S-drive site https://workhorsepainting.com
User 379556 Photo


Registered User
1,533 posts

mark johnson wrote:
Can anyone show me (or tell me) what everything needs to look like so they will be collapsed to begin with?

The matter seems controlled by the containers with the following id names: CollapseOne, CollapseTwo, and Collapse Three. Removing the Bootstrap class 'show' from each of them seems to do the trick.

Frank

PS I think the first example in the link referred to means that, but fails to make its meaning clear.
User 283347 Photo


Registered User
388 posts

Thanks for the help, guys.

Frank...there is no class show given by default...I only tried that after looking at the link I provided...as is, the only class associated with "collapseOne", etc. is 'card-header' I tried adding class show and undoing the attributes to match but I never found a configuration that worked.

GregB...thanks. I don't typically use Bootstrap as I have not found as much help with it...but I thought I would use one of the BS themes to make a site. I guess I should use it more. ha! Thanks for the suggestion, though.

Mark
User 379556 Photo


Registered User
1,533 posts

mark johnson wrote:
Frank...there is no class show given by default.

I've put a small screen-cast here to show what I meant.

Frank
User 283347 Photo


Registered User
388 posts

Thanks, Frank!! I was totally overlooking that one!!
Thanks for your time.
Mark

Have something to add? We’d love to hear it!
You must have an account to participate. Please Sign In Here, then join the conversation.