> The easiest way to get wiki-formatted output from a bookmarklet is to
> store the output in a shadow tiddler and then display that shadow,
> like this:
>
> config.shadowTiddlers.DocumentInfo = out;
> story.displayTiddler(null,'DocumentInfo');

I'm not sure I know how to do that with a script doesn't that require
systemConfig, at any rate I don't know where to start.

Also I don't know why the last line of the data falls outside the
table.  Here's the final script, can you see what's happening?


---------------------
<script label="Plugin Identifier">
                var 
plugins=window.store.getTaggedTiddlers('systemConfig','title');
                var out="|bgcolor:#abf; Title |bgcolor:#abf; Date |
bgcolor:#abf;padding-left:1em;Size|bgcolor:#abf; Author |bgcolor:#abf;
Version |bgcolor:#abf;CoreVersion |h\n";
                out+=plugins.map(function(t)
           {
               return '|[['+t.title+']]|'
                 +t.modified.formatString('YYYY.0MM.0DD')
                 +'| '+t.text.length
                 +'|'+store.getTiddlerSlice(t.title, "Author")
                 +' |'+ store.getTiddlerSlice(t.title, "Version")
                 +' |' + store.getTiddlerSlice(t.title,
"CoreVersion");
           }).join('|\n');
             return out;
</script>
------------------------

Morris

On Feb 12, 1:43 am, Eric Shulman <[email protected]> wrote:
> > Thanks FND, and Eric I took your code and got this far,  You know how
> > I like tables:-)  But I think it needs to be wikified or something
> > could you help me to make a table? That's the first step then I'd like
> > to make a bookmarklet from it.
> > ------------------------
>
> Unlike a regular inline script, there is no current 'place' defined
> when processing a bookmarklet, so you can't simply return some text
> containing wiki syntax, because there's nowhere to render that
> content... that's why the ShowDocumentInfo script uses an alert()
> dialog to display the output.
>
> The easiest way to get wiki-formatted output from a bookmarklet is to
> store the output in a shadow tiddler and then display that shadow,
> like this:
>
> config.shadowTiddlers.DocumentInfo = out;
> story.displayTiddler(null,'DocumentInfo');
>
> enjoy,
> -e
> Eric Shulman
> TiddlyTools / ELS Design Studios
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TiddlyWikiDev" 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/TiddlyWikiDev?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to