Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
How can I load the galleria-1.2.8.min.js from here:
https://greenringproject.googlecode.com/files/galleria-1.2.8.min.js
or this:
//cdnjs.cloudflare.com/ajax/libs/galleria/1.2.9/galleria.min.js
I found this in the galleria.module and since I am no expert in php I would need some help loading the js file from the link above.
/*
* Returns the JavaScript file of the Galleria core.
* Uses a cached filename until this file gets deleted or the cache gets cleared.
*/
function galleria_get_library_file() {
$cache = cache_get('galleria_lib_file');
if (($cache !== FALSE) && file_exists($cache->data))
return $cache->data;
// Search for library file
$libpath = libraries_get_path('galleria');
// Seach for minimized files first.
// Sort the found files to use the newest version if there's more than one.
$js = glob($libpath . '/galleria-*.min.js');
if (count($js) == 0)
$js = glob($libpath . '/galleria-*.js');
if (count($js) > 0) {
rsort($js);
cache_set('galleria_lib_file', $js[0]);
return $js[0];
}
else {
// Could not find JavaScript library
return FALSE;
}
}
Thanks a lot!