I am trying to add the Turn Editing On/Off button to my custom theme and I use the following code
But nothing is being printed. So I var_dump($PAGE->button) and I get
Does anyone have an idea why this is happening? Note that If I change the theme to something else, Turn Editing On button works fine.