Internal control panel links should be generated with the ee('CP/URL')
helper function which generates control panel URLs based on parameters
passed in.
For example, to link to the publish
controller, pass it in
as the first parameter to ee('CP/URL')
:
To link to a particular method in a controller, add it to the parameter
with a slash:
ee('CP/URL', 'publish/method_name');
If the method accepts arguments, they can be passed in cleanly by adding
them on the end separated by a slash:
ee('CP/URL', 'publish/method_name/5');
If the link requires any other GET parameters, they can be passed in via
an associative array in the second parameter:
ee('CP/URL', 'publish/edit', array('filter_by_channel' => $channel_id));
See CP/URL Service for the full documentation.