Oooops....spoke too soon

the script example works perfectly when I put it into the
MainMenu...it  displays the tiddlers as expected..

but when I tried to incorporate it into the bit of javascript that is
activated by the forms "Pass Go" button...the script does not
complete....although it was functioning before I added this part....I
guess I am writing the code wrong......what i now have inside the
button script for this part.....is...

var extratags =" ";
story.forEachTiddler(function(title, tiddler){
text += title+" ";
});

I have changed the single quotes to doubles as I am inside the single
quotes of the onClick expresion...and I want to be able to the reult
as the variable extratags...to add it into the tags list for the new
tiddler.......

...whats wrong with this code??

Thanks in Advance
Skye

On 3 Set, 19:03, skye riquelme <riquelme.s...@gmail.com> wrote:
> Thanks Mario.......I was not aware of that function.....it gives me a
> list of all tiddlers open in main window......and I was planning to
> run with SinglePageMode activated anyway...so it gives me exactly what
> I asked for...
>
> perfect
>
> WOW thats three perfect solutions in the same day....you guys are
> great !!!
>
> Skye
>
> On 3 Set, 17:38, PMario <pmari...@gmail.com> wrote:
>
> > Hi,
> > There is a forEachtiddler function in the story prototype [2].
> > And a short script, to demonstrate, how it works [1]
>
> > <script label="click me">
> >         var text = '';
> >         story.forEachTiddler(function(title, tiddler){
> >                 text += title + '\n';
> >         });
> >         return '\n\n' + text;
> > </script>
>
> > have fun!
> > mario
>
> >http://hoster.peermore.com/recipes/TeamWork/tiddlers.wiki#StoryForEac...
>
> > On Sep 3, 7:32 pm, skye riquelme <riquelme.s...@gmail.com> wrote:
>
> > > Hi All
>
> > > The title could sound rather esoteric.....actually its a simple code
> > > question.
>
> > > I have some code sitting in a widened MainMenu (at left) that is
> > > similiar to Erics QuickNote plugin....input into some html boxes,
> > > press "Pass GO" and it creates a new tiddler...out of thin air!!!!!
>
> > > What I want is to be able to have this new tiddler automatically
> > > linked to the tiddler that is currently open in the display
> > > window ........so do I have something store.getTiddlerTitle
> > > (current.mainwindow.tiddler) that I can add into the "var tags ="
> > > calculation under the "Pass GO" botton.
>
> > > Thanks in Advance
> > > Skye

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To post to this group, send email to tiddlyw...@googlegroups.com.
To unsubscribe from this group, send email to 
tiddlywiki+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/tiddlywiki?hl=en.

Reply via email to