^

CommentFileSizeAuthor
#6 901366_anchor_title_tag.diff3.8 KBMGN

Comments

MGN’s picture

Status: Active » Postponed (maintainer needs more info)

This probably needs a little explanation....

Michsk’s picture

explanation... the <a> tag should have a title atribute in it that is set based on the <a title="value">value</a> of the link.

heyyo’s picture

We need this extra HTML attribute on the a HTML tag. This title tag is recommended to be used on links to help Google to understand what the subject of page linked. So it's good for SEO.
Feed automatically the tag with the breadcrumb title could be nice idea, but for better result it should be manual.

Maybe on the title breacrumb we could add an extra pipe to add this new title tag:

Title:
[term]|Find all about [term]
[title]|[slogan]

Path
url1
url2

MGN’s picture

Status: Postponed (maintainer needs more info) » Active

Thanks for the explanation. This does seem worthwhile and it should probably go into custom_breadcrumbs_identifiers as a new type of special identifier. Perhaps a slight modification of your suggestion like:

Title |<title>Title attribute

would work?

But this would require some modifications to the way that special identifiers are used. Currently they are only processed as part of the path, and only at the beginning of a path specification. Still, I don't think this would be difficult to extend into the title specification.

heyyo’s picture

Title |Title attribute

Not sure to understand what do you mean by <title> ?

To be more clear of what we need is the result breadcrumb according my previous example:

<a href="path1" title="Find all about MYTERM">MYTERM</a> >> <a href="path2" title="SLOGAN">TITLE</a>

you could see the title attribute by passing your mouse on the links:
MYTERM >> TITLE

But this would require some modifications to the way that special identifiers are used. Currently they are only processed as part of the path, and only at the beginning of a path specification. Still, I don't think this would be difficult to extend into the title specification.

This will be great MGN :-)

MGN’s picture

Status: Active » Needs review
StatusFileSize
new3.8 KB

Actually, heyyo, I think your approach works fine without having to use special identifiers at all. This patch (against the latest 6.x-2.x-dev) uses the title specification shown in #3 (i.e. Crumb Title|Title Tag). The title attribute can also be added for the home breadcrumb text using the same format on the Custom Breadcrumbs Configuration page (admin/settings/custom-breadcrumbs). I've also added a few lines of documentation on the relevant forms. This needs testing. Let me know what you think.

heyyo’s picture

Thnaks for your amazing service and reactivity :-) You're awesome !
I will check it today.

heyyo’s picture

Feedback on the home breadcrumb:
When saving any home text with a pipe, everything after the pipe (including the pipe) is removed and not saved. it's maybe because of my multilang website ? Not sure if it was displayed before patching, but I don't see "multilingual variable" under the home text field.

EDIT: it's saved but strangely in other language only !
When I save the hom text in english i'ts empty in english and filled in French :-)
When I save in French it saves correctly in French (no changes in other language)

Feeback on custom breadcrumbs pages
Work great :-) I tried with regular text and also tokens, evrything is correctly handled.

Michsk’s picture

Nice that's quick. I will give it a go as soon as im back behind the work laptop.

MGN’s picture

@heyyo, that's interesting. Let me make sure I understand this. You enter some home breadcrumb text with a title attribute (separated by a pipe) in the Home breadcrumb text field at admin/settings/custom-breadcrumbs and press the Save Configuration button, and everything following (and including) the pipe is removed from the text field?

I haven't tested this on a multilanguage site, so I am not sure what cause this behavior - perhaps a problem with the pipe character itself on multilanguage sites?

Out of curiosity, have you listed 'custom_breadcrumb_home' as an i18n variables (as is shown for other module defined variables, for example, at http://drupal.org/node/313272) ?

heyyo’s picture

@heyyo, that's interesting. Let me make sure I understand this. You enter some home breadcrumb text with a title attribute (separated by a pipe) in the Home breadcrumb text field at admin/settings/custom-breadcrumbs and press the Save Configuration button, and everything following (and including) the pipe is removed from the text field?
Yes exactly.

My fault :-) You were right custom_breadcrumb_home was not defined anymore in my settings.php, I switched to another host and forgot to upload it.
So everythjing is working perfectly now. But by the way it was a really strange bug.

Thanks

MGN’s picture

Status: Needs review » Fixed

Great. I've committed this new feature to 6.x-2.x-dev, though additional testing is encouraged.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.