0

I am using Drupal 7 and I have some shortcut sets (per role using the shortcut per role module) and shortcut links in them and I would like to export them either using the features functionality or with any other exporting mechanism.

But I do not find any relevant exportables in the features exporting options not even in the Strongarm section. Is there a way yo do this or should I manually recreate them in the other site installations?

I have also seen a relevant question but it does not have any answers regarding the shortcuts part.

2

Finally, managed to programmatically create the shortcut sets and links with the following php script:

<?php
echo 'populating shortcuts...';
$shortcut_set = new stdClass();
$shortcut_set->title = 'Default';
$shortcut_set->set_name = 'shortcut-set-1';
$shortcut_set->links = array(
    array('link_path' => 'admin', 'link_title' => 'Admin',),
);
shortcut_set_save($shortcut_set);
echo ' shortcuts population finished';
?>

as mentioned in this drupal post.

A also had to apply this patch in shortcut module, which fixes the shortcut_set_save function called by the script.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.