Hi
Made some tests.
Would be cool if it is a small plugin
[1]
http://hoster.peermore.com/recipes/TeamWork/tiddlers.wiki#ReferencesNewColor%20ReferencesNewColor_ref
I found, that (this) points to Window.something
and jQuery('.command_references') finds every button on the page so
changed it to jQuery('#tiddler'+ because every tiddler has an ID.
<script>
if (store.getReferringTiddlers(tiddler.title)) {
jQuery('#tiddler'+tiddler.title).find('.command_references').css("color","red");
}
</script>
Needs more testing.
Would be cool, if you post your result at the TeamWork TW[1], or a
link to your finished plugin, if there will be one :)
have fun!
Mario
On May 27, 10:06 am, Alex Hough <[email protected]> wrote:
> This script is an attempt to color ‘references’ in the toolbar red if
> the tiddler has references.
> It doesn't work.
>
> <script>
> var title = store.getTiddler(this);
> var references = store.getReferringTiddlers(title);
> if (references.length > 0) {
> jQuery('.command_references').css("color","red");
> }
> </script>
>
> Any hints and tips?
>
> thanks in advance
>
> Alex
--
You received this message because you are subscribed to the Google Groups
"TiddlyWiki" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/tiddlywiki?hl=en.