Last modified: 2011-11-18 03:35:50 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T34106, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 32106 - #formlink: `title' parameter.
#formlink: `title' parameter.
Status: VERIFIED FIXED
Product: MediaWiki extensions
Classification: Unclassified
SemanticForms (Other open bugs)
unspecified
All All
: Unprioritized enhancement (vote)
: ---
Assigned To: Yaron Koren
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-10-31 23:47 UTC by Van de Bugger
Modified: 2011-11-18 03:35 UTC (History)
1 user (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments
Implementation of `title' parameter. (9.55 KB, patch)
2011-10-31 23:47 UTC, Van de Bugger
Details

Description Van de Bugger 2011-10-31 23:47:07 UTC
I want to specify `title' attribute for `a' element generated by `#formlink' function. Content of `title' attribute is displayed as a small "tooltip" when mouse cursor stays over a link.
Comment 1 Van de Bugger 2011-10-31 23:47:53 UTC
Created attachment 9335 [details]
Implementation of `title' parameter.
Comment 2 Yaron Koren 2011-11-02 03:21:48 UTC
I think the patch could have been a little shorter than that. :) Anyway, thanks for the good idea - I just added this in to the SVN code.
Comment 3 Van de Bugger 2011-11-02 19:12:34 UTC
Try 

{{ #formlink: ... | title = ⚒ }}

tooltip would be "✐", while I would expect "⚒". You made the implementation shorter, but throw away useful code:

// Decode `$inTitle' first to get character entities (e. g. `→') replaced with
// characters. Without this, `encodeAttribute' will replace `&' with `&' so
// character entities in tooltip will be preserved, e. g. `→' will be shown
// as-is, not as right arrow.
$inTitle = Sanitizer::decodeCharReferences( $inTitle );

Could you please insert it back?
Comment 4 Yaron Koren 2011-11-02 20:35:23 UTC
Ah, indeed - I couldn't think of a case where that was necessary, but this is such a case. I just added that code in; thanks.
Comment 5 Van de Bugger 2011-11-02 23:28:54 UTC
Ok, now it works. Thanks.
Comment 6 Yaron Koren 2011-11-18 03:35:50 UTC
I just changed the name of this parameter from 'title' to 'tooltip', because I thought it was a clearer name - sorry for the inconvenience.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links