Add another Options page #476
-
I've successfully added a couple of components to the Global Options page - I'd now like to move one of those onto its own Options page. I tried the standard ACF Pro code in the main functions.php but it just causes errors. I also tried fiddling with code in lib/utils/options.php but without success - anyone know how to do this? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Hi @Iain-g would suggest to add subpages to the existing two option pages. If you want use them, you can use the 3rd argument of the /* Create a Global Option subpage */
Options::addGlobal('NameOfTheComponent', [], 'NameOfTheSubpage');
/* Create a Translatable Option subpage */
Options::addTranslatable('NameOfTheComponent', [], 'NameOfTheSubpage'); Does this match your expectations? |
Beta Was this translation helpful? Give feedback.
Hi @Iain-g would suggest to add subpages to the existing two option pages. If you want use them, you can use the 3rd argument of the
addGlobal
andaddTranslatable
functions, to define the name of the subpage and the rest will be done automatically:Does this match your expectations?