It might be that this ...
if
(["Yes","yes","Y","y"].contains(store.getTiddlerSlice(val1,"Purchased")))
continue;
needs to be this ...
if
((new
Array("Yes","yes","Y","y")).contains(store.getTiddlerSlice(val1,"Purchased")))
continue;
If you have your code with a sub-set of sample data somewhere like
tiddlyspot, then perhaps one or more of us could look it over.
Mark
On Feb 13, 3:16 pm, Mike <[email protected]> wrote:
> Thank You !
>
> 1st option works perfect, 2nd option (one liner) returns
> undefined. . .
>
> Any benefits of return vs wikify? (Other than they are both better
> than document.write)
>
> I appreciate your input,
>
> Mike
>
> On Feb 13, 2:39 pm, Eric Shulman <[email protected]> wrote:
>
> > > Is their a way to put multiple conditions on one line I.E.
> > > if (store.getTiddlerSlice(val1,"Purchased") != "Yes,
> > > yes, Y, y") continue;
>
> > var val=store.getTiddlerSlice(val1,"Purchased");
> > var choices=["Yes","yes","Y","y"];
> > if (!choices.contains(val)) continue;
>
> > or.. .written as one line, without temp variables:
>
> > if
> > (["Yes","yes","Y","y"].contains(store.getTiddlerSlice(val1,"Purchased")))
> > continue;
>
> > enjoy,
> > -e
> > Eric Shulman
> > TiddlyTools / ELS Design Studios
>
>
--
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.