This question is answered. Helpful answers available: 2. Correct answers available: 1.


Permlink Replies: 15 - Pages: 2 [ 1 2 | Next ] - Last Post: 10-May-2020 03:40 Last Post By: jGromit Threads: [ Previous | Next ]
RJLaBella

Posts: 23
Registered: 22-Apr-2007
Neptune - Add Filename to Slide Caption
Posted: 13-May-2018 22:14
 
  Click to reply to this thread Reply
I would like to have the slide caption show the Image title and have the file name (without extension) appended to the caption text of a photo.
I would like it to have the following format:
Slide Title (Image#)
for example: Lighthouse (18-1234-1)

I am aware that the filename icon (the camera) shows on the slide border, but not everyone will know to click on that to get the filename. I think it would be better to eliminate the "camera" icon and actually show the filename.
jGromit

Posts: 7,653
Registered: 31-Jan-2006
Re: Neptune - Add Filename to Slide Caption
Posted: 14-May-2018 02:12   in response to: RJLaBella in response to: RJLaBella
 
  Click to reply to this thread Reply
The Neptune skin has no built-in way of doing that. The caption options are restricted to file tItle or file name if no title has been entered, and then the comment. In fact, none of my skins provides a way to do that - until now, no one has ever asked for it.

You could code-hack the includes/slide.inc script in the skin to display the title and the name - the file name without extension is the jAlbum variable label. I'm on the road at the moment, but post back if you get stuck trying to do that, and I'll cough up some code changes to do this when I get some time.

Edit: Correction - the place to do this would be in includes/objvars.inc.

It's actually a pretty simple change. Launch jAlbum and choose Neptune. Then choose Tools, Skin developer, Edit skin files. The editor will open, with several files already open for editing, but not the one you want. Choose File, Open, open the includes directory, then open objvars.inc.

You need to insert only one line:
After this line:
 
ctStitle = cleanString(fileTitle);
 
Insert:
 
if(ctStitle != null) ctStitle += " (" + ctSlabel + ")";

I haven't tested this, but it should do what you want.

Edited by: jGromit on 14-May-2018 08:45
RJLaBella

Posts: 23
Registered: 22-Apr-2007
Re: Neptune - Add Filename to Slide Caption
Posted: 14-May-2018 18:20   in response to: jGromit in response to: jGromit
 
  Click to reply to this thread Reply
Great! Worked like a charm. Thanks for the quick response.

Can I also remove the "camera" (filename) icon from the slide frame? It is now redundant.
jGromit

Posts: 7,653
Registered: 31-Jan-2006
Re: Neptune - Add Filename to Slide Caption
Posted: 14-May-2018 23:21   in response to: RJLaBella in response to: RJLaBella
 
  Click to reply to this thread Reply
Sure, just uncheck all of the choices on the Metadata tab. This code change is just using standard jAlbum variables (after a bit of cleaning up by the skin), rather than trying to display metadata.
RJLaBella

Posts: 23
Registered: 22-Apr-2007
Re: Neptune - Add Filename to Slide Caption
Posted: 15-May-2018 23:23   in response to: jGromit in response to: jGromit
 
  Click to reply to this thread Reply
Worked, thanks again
RJLaBella

Posts: 23
Registered: 22-Apr-2007
Re: Neptune - Add Filename to Slide Caption
Posted: 09-May-2020 03:39   in response to: RJLaBella in response to: RJLaBella
 
  Click to reply to this thread Reply
I just noticed that the latest version of Neptune no longer has
includes/objvars.inc.

Has the skin setup been changed? I want to have the slide caption show the Image title and have the file name (without extension) appended to the caption text of a photo.
I would like it to have the following format:
Slide Title (Image#)
for example: Lighthouse (18-1234-1)
jGromit

Posts: 7,653
Registered: 31-Jan-2006
Re: Neptune - Add Filename to Slide Caption
Posted: 09-May-2020 15:30   in response to: RJLaBella in response to: RJLaBella
 
  Click to reply to this thread Reply
It's now in includes/iterate.inc, at line 47.

But I'm not sure why you're paying attention to something tiny like this, when your site is still an iframed mess. I spent considerable time working out a solution for you, but you've ignored it. That makes me less inclined to help in the future.

https://jalbum.net/forum/thread.jspa?threadID=55523

Worrying about slide titles in these circumstances is a bit like rearranging the pictures on the living room wall of a house that's on fire.
RJLaBella

Posts: 23
Registered: 22-Apr-2007
Re: Neptune - Add Filename to Slide Caption
Posted: 09-May-2020 19:05   in response to: jGromit in response to: jGromit
 
  Click to reply to this thread Reply
I've been away from my office since the start of the year and hope to be back at my office computer by July.
Also, I am not a web expert, so have been plodding slowly thru your instructions on my laptop which is limited..
I have not ignored this project, and with this pandemic keeping us in, hope to be able to get it completed.

Thanks for your help & patience.
RJLaBella

Posts: 23
Registered: 22-Apr-2007
Re: Neptune - Add Filename to Slide Caption
Posted: 09-May-2020 22:31   in response to: RJLaBella in response to: RJLaBella
 
  Click to reply to this thread Reply
I found the demo1 album I had been working on in my backup disk & loaded it on my laptop & am picking up where I left off.

I have been able to use the template to convert the existing albums to iFrame-less design, but am still stuck on getting the Slide caption to show the Title (fileneme) format. Includes\iterate.inc has the mod to do this, but it is not showing up. Only the filename shows.

Is there something else in demo1 that I need to change to get this. Getting close to be able to roll this out, but I need to have the Title & Filename in the slide captions so customers can easily identify the images they are interested in purchasing.

Thanks for putting the demo1 together as I doubt I would have been able to pull that off succesfully.
jGromit

Posts: 7,653
Registered: 31-Jan-2006
Re: Neptune - Add Filename to Slide Caption
Posted: 09-May-2020 22:49   in response to: RJLaBella in response to: RJLaBella
 
  Click to reply to this thread Reply
Works in my quick test. The includes/iterate.inc file before modification, lines 47-48:
ctStitle = cleanString(fileTitle);
if(ctStitle == null && iscUseName) ctStitle = ctSlabel;
After editing, lines 47-49:
ctStitle = cleanString(fileTitle);
if(ctStitle != null) ctStitle += " (" + ctSlabel + ")";
if(ctStitle == null && iscUseName) ctStitle = ctSlabel;
If you're getting just the file name, I suspect you've entered just an = instead of a += in the new line.
RJLaBella

Posts: 23
Registered: 22-Apr-2007
Re: Neptune - Add Filename to Slide Caption
Posted: 09-May-2020 23:19   in response to: jGromit in response to: jGromit
 
  Click to reply to this thread Reply
I have:
ctStitle = cleanString(fileTitle);
if(ctStitle != null) ctStitle += " (" + ctSlabel + ")";
if(ctStitle == null && iscUseName) ctStitle = ctSlabel;
stStitle = stripString(ctStitle);
and this is working correctly for my "old" albums.

Might there be a setting in the config UI that overrides this?

jGromit

Posts: 7,653
Registered: 31-Jan-2006
Re: Neptune - Add Filename to Slide Caption
Posted: 09-May-2020 23:24   in response to: RJLaBella in response to: RJLaBella
 
  Click to reply to this thread Reply
You are actually entering a title for each image, right? In the jAlbum Explore view, click Title at upper right. If you're seeing something like mydog.jpg under each thumbnail, you haven't entered a title for that image. And if that's the case, you'll get just the label, i.e., the file name without its extension.
RJLaBella

Posts: 23
Registered: 22-Apr-2007
Re: Neptune - Add Filename to Slide Caption
Posted: 09-May-2020 23:29   in response to: jGromit in response to: jGromit
 
  Click to reply to this thread Reply
Found the issue - Jalbum settings needed changing. All is now well as far as I can see so far,

Advanced | Metadata selections needed changes.

Thanks much

Edited by: RJLaBella on 09-May-2020 17:30
jGromit

Posts: 7,653
Registered: 31-Jan-2006
Re: Neptune - Add Filename to Slide Caption
Posted: 09-May-2020 23:37   in response to: RJLaBella in response to: RJLaBella
 
  Click to reply to this thread Reply
RJLaBella wrote:
Advanced | Metadata selections needed changes.

Ah, yes - I always have most of those turned off because they tend to dredge up all manner of random junk from the files. Other applications put all kinds of garbage into some of the IPTC fields, in particular, and Windows does you the "favor" of putting some stuff in the EXIF metadata. It's a minefield. ;)
RJLaBella

Posts: 23
Registered: 22-Apr-2007
Re: Neptune - Add Filename to Slide Caption
Posted: 10-May-2020 03:35   in response to: jGromit in response to: jGromit
 
  Click to reply to this thread Reply
Got my "beta" page built & uploaded. Also added FB Like & Share buttons, Slide captions with Title & Filename. At some point I want to figure out how to change the font color of "My Favorites" in the menu to Gold, but that is a really low priority.

https://rjlabellaphotos.com/Albums/Favorites1/

Glad to see the scroll bars relegated to history, thanks for such great support.

Now I will have to start updating all the albums on the website. Gonna take forever.

Thanks,
Rich LaBella
Legend
Forum admins
Helpful Answer
Correct Answer

Point your RSS reader here for a feed of the latest messages in all forums