Hello there.
I am building custom install profiles and themes as "template packages" (to be used with the Acquia Drupal distribution) for end users to have a "turnkey" website solution. This Advanced Help module seems a perfect solution for me to use in the install profile (which configures views, node types, CCK fields, et all) to lead the website owner through the process of understanding the architecture and setting up the website content after installation. My sites use the Acquia Drupal distribution so that the end users can keep Drupal core and all modules up to date with ONE download from Acquia. They will also need to download my related theme and install profile, but I'd like to keep the downloads to a minimum. For this reason I am not building a separate module to go with each site.
I would like to set up help files in my profile for this Advanced Help module to read from. I'm not an advanced module developer, but know my way around Drupal enough to have explored the possibilities, and made the necessary (first draft) changes to the Advanced Help module. I don't have a way to create "DIFF" files, so here's what I've modified. I hope to see this functionality (rather simple modification) in a future release.
/*
* Original function in "advanced_help.module"
*/
function _advanced_help_parse_ini() {
static $cache = NULL;
if (!isset($cache)) {
$cache = array('topics' => array(), 'settings' => array());
$help_path = drupal_get_path('module', 'advanced_help') . '/modules';
foreach (module_list() as $module) {
$module_path = drupal_get_path('module', $module);
$info = array();
/*
* get help files for each "module" .....
*/
}
drupal_alter('advanced_help_topic_info', $cache);
}
return $cache;
}
/*
* Modified function to include help files from the active profile
*/
function _advanced_help_parse_ini() {
static $cache = NULL;
if (!isset($cache)) {
$cache = array('topics' => array(), 'settings' => array());
$help_path = drupal_get_path('module', 'advanced_help') . '/modules';
$sources = array();
// add active profile to sources array
if ($profile = variable_get('install_profile','default')){
$sources[$profile] = 'profiles/'.$profile;
}
// add modules to sources array
foreach (module_list() as $module) {
$sources[$module] = drupal_get_path('module', $module);
}
// we could add themes here too ...
foreach ($sources as $module => $module_path) {
$info = array();
/*
* get help files for each "module" .....
*/
}
drupal_alter('advanced_help_topic_info', $cache);
}
return $cache;
}
Thanks,
M.M.
Comments
Comment #1
redndahead commentedYou can create your own module and have it pull the advanced help files from there for your install profile. As for theme handling this would be a duplicate request of http://drupal.org/node/401810