Hey folks,
i try to initially set the default settings through a install profile.
Due to the fact, that default settings are only saved after submitting the theme settings form once i used drupal_submit_form. In 7.x-2.x wasn't any problems with this method. 7.x-3.1 thowing these errors
array_unique() expects parameter 1 to be array, null given in [warning]
at_get_plugins() (line 38 of
/home/travis/build/GlobalGameport/beta.ggp.com/profiles/ggp_net/themes/adaptivetheme/at_core/inc/plugins.inc).
Invalid argument supplied for foreach() in at_get_plugins_files() [warning]
(line 83 of
/home/travis/build/GlobalGameport/beta.ggp.com/profiles/ggp_net/themes/adaptivetheme/at_core/inc/plugins.inc).
More at: https://travis-ci.org/GlobalGameport/ggp_profile/jobs/10639367
Here is a snippet of what i use for send
module_load_include('inc', 'system', 'system.admin');
// Do this to automate saving the theme settings form:
foreach (array('ggp_theme') as $theme_name) {
$form_state = form_state_defaults();
$form_state['build_info']['args'][0] = $theme_name;
$form_state['values'] = array();
drupal_form_submit('system_theme_settings', $form_state);
}
This is the profile i'm using: https://github.com/GlobalGameport/ggp_profile/blob/7.x-1.2/ggp_net.profile
This is the theme: https://github.com/GlobalGameport/ggp_theme
I found nothing similar in the issue list. Is there anybody with the same problems or a solution?
Comments
Comment #1
Jeff Burnz CreditAttribution: Jeff Burnz commentedUse the development version, it has a lot of changes to support Drupal Commons which does the same thing on install.
Comment #2
valkum CreditAttribution: valkum commentedthanks. works well.