Hide delete button for a specific section in accordion


#1

I have a SEssentialsAccordion with custom Sections, and Headers. Everything works really well… except…

I want to be able to set a single section to be not editable. For instance if there is a specific section that I do not want deleted, is there some setting I can put on a section so it doesn’t show the delete button for a specific section?

I can override the remove button, but it would be nice if it didn’t show.

Thanks,

Jeff


#2

Hi Jeff,

Unfortunately there’s no way to do this out-of-the-box.

If you’d prefer not to have the remove button present at all in some sections, then one possibility (which I haven’t tried for myself) would be to set the accordion’s editing property to be false, and then for the sections you do want to edit/delete, add your own buttons into the content header (as described in your previous thread), which then call the relevant methods on the accordion to remove the section.

I hope that helps you to find a suitable solution.

Kind regards,

Alison


#3

Thanks. I was just curious if it changed. I know about the override, but I wanted to know if there was an easier way by now.

I just overrode them anyhow.

Thanks for the response.