function superfish_library_path in Superfish 6
Same name and namespace in other branches
- 8 superfish.module \superfish_library_path()
Generate the default path for the Superfish library.
2 calls to superfish_library_path()
- superfish_menu_settings in ./
superfish.admin.inc - Module settings form.
- superfish_menu_settings_validate in ./
superfish.admin.inc - Implements hook_validate().
File
- ./
superfish.admin.inc, line 11 - Functions that are only called on the admin pages.
Code
function superfish_library_path() {
// Ensure the Libraries API module is installed and working.
if (module_exists('libraries') && function_exists('libraries_get_path')) {
$directory = libraries_get_path('superfish');
}
else {
$directory = 'sites/all/libraries/superfish';
}
if (file_exists($directory)) {
$output = $directory . "/jquery.hoverIntent.minified.js\n" . $directory . "/jquery.bgiframe.min.js\n" . $directory . "/superfish.js\n" . $directory . "/supersubs.js\n" . $directory . "/supposition.js\n" . $directory . "/sftouchscreen.js\n" . $directory . "/sfsmallscreen.js\n" . $directory . "/sfautomaticwidth.js";
}
else {
$output = '';
}
return $output;
}