readOnly (no options)

29 views
Skip to first unread message

Mike

unread,
Apr 2, 2010, 2:38:38 PM4/2/10
to TiddlyWiki
I know I have seen this somewhere, but can't seem to find it. . .
I would like a TW, if in readOnly, to not show options . . .
<<slider chkSliderOptionsPanel OptionsPanel "options »" "Change
TiddlyWiki advanced options">>

Any Ideas?

Mike

(P.S. I can always remove the reference from SideBarOptions, but was
looking for a better way)

Eric Shulman

unread,
Apr 2, 2010, 5:05:34 PM4/2/10
to TiddlyWiki
> I would like a TW, if in readOnly, to not show options . . .
> <<slider chkSliderOptionsPanel OptionsPanel "options »" "Change
> TiddlyWiki advanced options">>

If you have InlineJavascriptPlugin, you can write:

{{wrapper{<<slider chkSliderOptionsPanel OptionsPanel "options »"
"Change TiddlyWiki advanced options">><script>
if (readOnly) place.style.display="none";
</script>}}}

Note that the <script>...</script> is inside the {{wrapper{...}}}, so
the the reference to 'place' is to the wrapper itself.

enjoy,
-e

Mike

unread,
Apr 2, 2010, 9:06:43 PM4/2/10
to TiddlyWiki
Awesome - Thank You,

I was looking at your post here:
http://groups.google.com/group/tiddlywiki/browse_thread/thread/b65e6ce2f0ac1af7/e36c4fad4bb6f852?lnk=gst&q=showvalue#e36c4fad4bb6f852

I thought the ShowValue transclusion would be a neat trick (since I am
using the Last Modified from that post already)
(is that even possible?.?)

I appreciate your response,

Mike

Reply all
Reply to author
Forward
0 new messages