The documentation on hook_link doesn't mention that having a title without an href will be themed without running through a l() call. This is a useful fact to know, and is contrary to the current documentation.

Comments

fax8’s picture

Status: Needs review » Reviewed & tested by the community

+1 Original documentation is really confused and incorrect.

Fabio Varesano

Caleb G2’s picture

For us following along at home - why is this useful to know? (example?)

bdragon’s picture

Status: Reviewed & tested by the community » Needs work

People porting custom 4.7 modules that used non-link links to show summary statistics and such.

*slaps forehead*
Doh! Forgot to provide an example....

fax8’s picture

Status: Needs work » Reviewed & tested by the community

my video module add video size and lenght to links in 4.7
(example: http://www.windsmpeg.tk/video+type/full+video)
they are only simple text and reading hook_link original
documentation I was not able to understand that I can also add simple text.

bdragon’s picture

Status: Reviewed & tested by the community » Needs work

C'mon man, leave the status alone for a few minutes ;). I'll CNR it when I have the updated patch ready . ;)

I'm using your example for the code section, btw.

bdragon’s picture

Status: Needs work » Needs review
StatusFileSize
new2.63 KB

Ok, this one has an example too...

RobRoy’s picture

Status: Needs review » Needs work

I'd change and to &&. Besides that looks pretty good.

bdragon’s picture

Status: Needs work » Needs review
StatusFileSize
new2.62 KB

Whoops, agree there, && is the way to go there... Shoulda read it better when copy/pasting.

bdragon’s picture

Status: Needs review » Fixed

Going once, going twice, SOLD!

Anonymous’s picture

Status: Fixed » Closed (fixed)