Move or duplicate a custom control button to other tab

Äääähm ...
plugin developer != me :stuck_out_tongue_closed_eyes:

That's what you think! :wink:

1 Like

O.k. so far I I got it to work.
Just a phenomenon I would like to understand:
when I use $('.custom_section').appendTo($('#temp'));
it works as expected, the buttons are moved to the temp-tab and all is fine, but when I use $('.custom_section').clone().appendTo($('#temp'));
the buttos are copied (cloned) to the temp-tab but they didn't work (the original buttons on the control tab still work fine)
What happens here, why does cloning not work as expected ???

Not that big problem as I found a kind of "workaround":
just put a second set of buttons with the same functions on the controll-tab and move only the second set to the temp-tab
$('.custom_section:nth-of-type(2)').appendTo($('#temp'));

Try with $('.custom_section').clone(true, true)
https://api.jquery.com/clone/

Thank you @fieldOfView works perfect.
Seems a typical case of RTFM - or "as soon as you make it correct it works" :grin:
In the future I should read the whole documentation, not only the first line ...

Or use Google to find someone with a similar question on StackOverflow and copy the top anser :wink:

2 Likes