By Jerimee on
How do I create menu items programatically?
I want to be able to create menus with either an installation profile, or by running code from the devel Execute PHP block.
Thanks for help.
How do I create menu items programatically?
I want to be able to create menus with either an installation profile, or by running code from the devel Execute PHP block.
Thanks for help.
Comments
Here's how to do it on node creation.
Here's how to do it on node creation. Would still like to know how to do it outside of node creation.
You can execute this with the devel execute php console:
Note for above code to work you need to have a user named "robo-user"