Announcement

#1 2017-10-16 16:28:30

jemostrom
Member
2015-04-29
23

Turn off file name in breadcrumbs

Is there some way to turn off the file name in the breadcrumbs?

For example on a photo I have "Home/Resursbilder/2017-05-16 19-37-50 00030", the album name is useful but the file names on my photos contains no info that should be displayed as a title.

Is there some option to turn this off? I tried to find something but failed.

Offline

 

#2 2017-10-17 07:31:16

eliz82
Member
Romania
2016-04-27
281

Re: Turn off file name in breadcrumbs

yes, I think is possible to remove.

go to your /themes/"your current theme folder"/ .
search the template "picture.tpl" , open in editor . ( if there is none, go to /themes/default/ )

look for this code

Code:

<div id="imageHeaderBar">
  <div class="browsePath">
    {$SECTION_TITLE}<span class="browsePathSeparator">{$LEVEL_SEPARATOR}</span><h2>{$current.TITLE}</h2>
  </div>
</div>

remove {$current.TITLE} and save the file.
purge the cache.

Last edited by eliz82 (2017-10-17 07:38:02)

Offline

 

#3 2017-10-18 09:18:03

jemostrom
Member
2015-04-29
23

Re: Turn off file name in breadcrumbs

Thanks

Offline

 

#4 2017-10-18 14:45:00

flop25
Piwigo Team
2006-07-06
7037

Re: Turn off file name in breadcrumbs

nope nope nope

Thanks for answering but here there are two major issues:
- you are changing core files that will be replaced at the next update
- a CSS solution exists and is easier

So revert your changes, use Localfile Editor, go to CSS and now add this code

Code:

.browsePath h2 {
display : none;
}

which means don't display the <h2> which a child of an html tag having the class "browsePath"
Because of : <div class="browsePath">
    {$SECTION_TITLE}<span class="browsePathSeparator">{$LEVEL_SEPARATOR}</span><h2>{$current.TITLE}</h2>

if you are using a specific theme, the ".browsePath h2" should be adapted


To get a better help : Politeness like Hello-A link-Your past actions precisely described
Check my extensions : more than 30 available
who I am and what I do : http://fr.gravatar.com/flop25
My gallery : an illustration of how to integrate Piwigo in your website

Offline

 

#5 2017-10-19 11:36:24

eliz82
Member
Romania
2016-04-27
281

Re: Turn off file name in breadcrumbs

flop25 wrote:

you are changing core files that will be replaced at the next update

I was so many years a user of Gallery2, sometimes I forgot Piwigo don't have template overwrite protection.

Offline

 

#6 2017-10-19 11:44:59

flop25
Piwigo Team
2006-07-06
7037

Re: Turn off file name in breadcrumbs

Well it does have a kind of it, it's called template extension and you can edit them through Localfiles editor


To get a better help : Politeness like Hello-A link-Your past actions precisely described
Check my extensions : more than 30 available
who I am and what I do : http://fr.gravatar.com/flop25
My gallery : an illustration of how to integrate Piwigo in your website

Offline

 

#7 2017-10-19 11:58:09

eliz82
Member
Romania
2016-04-27
281

Re: Turn off file name in breadcrumbs

flop25 wrote:

Well it does have a kind of it, it's called template extension and you can edit them through Localfiles editor

Thanks ... I didn't knew that, this is useful to me as I have around 10 modified template files. I will search and try that extension.
I usually when I edit them on the webserver I copy them to my local computer to have a backup if overwriting them accidentally.

p.s. I have added to github an idea to use the same method as gallery2 to not overwrite the templates [Github] Piwigo issue #798 . In gallery2 this was implemented in the core and you could use it in all extensions.

Last edited by eliz82 (2017-10-19 11:59:40)

Offline

 

Board footer

Powered by FluxBB

github twitter newsletter Donate Piwigo.org © 2002-2022 · Contact