RSGallery2 support forums > Features requests !

Shorter Filename in EXIF info?


Hello, not really sure what forum this should go in..

System Info:
Database Version:    5.1.38
PHP Version:    5.2.9
Web Server:    Apache/2.2.20 (CentOS)
Web Server to PHP interface:    apache2handler
Joomla! Version:    Joomla! 1.5.18 Stable (Not most recent I know!)

Installed RSGallery2 version:   2.3.0 (SVN 1097)
Installed Site Template: Juli (downloaded from

Okay, so, the person I am doing this gallery for would like a shortened version of the FileName path in the EXIF info. They feel that the whole path is not necessary for their use and would rather just know the exact file name and type (IE simpy: image.jpg). The red boxed out part shown below is what I would like to accomplish:

I am unsure if there is a way in PHP that the path could be cut down to only the part I need or if I could capture this info another way..


Find the file /JOOMLAROOT/components/com_rsgallery2/lib/exifreader/exifReader.php where in function getImageInfo you'll see on line 1608

--- Code: ---$retArr["FileName"] = $imgInfo["FileName"];

--- End code ---
Change that to

--- Code: ---$retArr["FileName"] = basename($imgInfo["FileName"]);

--- End code ---
to get just the filename (see

Keep a note of what you've changed since this change will be overwritten if you ever reinstall/update RSGallery2.

This change can be applied for both RSGallery2 version 2.3.0 for Joomla 1.5 and version 3.2.0 for Joomla 2.5.

Awesome, thank you much! I was trying to see if there was a PHP function that did that.

Your support has been great!


[0] Message Index

Go to full version