Then what did you mean when yousaid:
>Be aware that something like [showif [instock]=3D1] is=A0
>the same= as [showif [instock]] as long as [instock]is=A0
>greater than zero when an item is actually in stock. It=A0>helps make the code a little bit morereadable, too.
Terry
On Wed, =5 Aug 2009 12:25:16 -0500
Patrick McCormick<pm@webdna.us> wrote:
> I'm sorry - you can't just use [showi=f [something]]
>There needs to be somesetup work to make this possible.
>
> [math show=3DF&mul=ti=3DT]a=3D1&b=3D2[/math]
> [textshow=3DF]compare=3D[raw][a]<[b][/raw][/text]
> [text show=3DF]re=sult=3D[interpret][terd][/interpret][/text]
>[showif [result]]toyboat[/showif]
>
>
> On Aug 5, 20=09, at 12:00 PM, Terry Wilson wrote:
>
>> Yeah, you're right of course. Can't believe I didn't see
>>that when I
>> wrote itout. Anyway, Marc's solution of two searches is
>>what I'd do =
>> too.
>>
>>Terry
>>
>> p.s so you're saying that [showif anyvalue]= will resolve
>>to true? No=20
>> comparison needed? This is the first I'm hearing about
&=gt;>this, and I'm
>> a prettyfaithful and long-time reader of the list.
>>
>> On Wed=, 5 Aug 2009 10:40:07 -0500
>> PatrickMcCormick <pm@webdna.us> wrote:
>> > Terry & Ki,
>> >
>> > I don't thinkthat will work because [instock] is only
>> >evaluated within= the [founditems] loop
>>>
>> > You need:
>> >
>> > [search= stuff...]
>> >[founditems]
>> > [hideif [instock]]
>> > [item f=ields]
>> > [/hideif]
>>> [/founditems]
>> > [/search]
>> >
>>=; > BOOL is a really cool part of WebDNA.Anything greater
>> >than zero is true and anything 0 or less= is false. That
>> >means that evenrandom strings of text are, technically
>> >true. You need to= avoid bad code practice, but there
>>>are some really clever and graceful things you can do.
>> &g=t;
>> > Be aware that somethinglike [showif [instock]=3D1] is
>> >the same as [showif [insto=ck]] as long as [instock] is
>>>greater than zero when an item is actually in stock. It
>> &=gt;helps make the code a little bit morereadable, too.
>> >
>> >
>> >
>=> >
>> > On Aug 4, 2009, at1:39 PM, Terry Wilson wrote:
>> >
>> >> So you= would have two founditems loops withinyour
>> >>search:
>> >>
>> >>=; [search stuff...]
>>>>
>> >> [hideif [instock]=3D0]
>> >>= [founditems]
>> >>...
>> >> [/founditems]
>> >> [/hideif]
=>> >>
>> >> [showif[instock]=3D0]
>> >> [founditems]
>> >> ...=
>> >> [/founditems]
>>>> [/showif]
>> >>
>> >> [/search]
>> >>
>> >> (sortby sku, not instock)
>> >>
>> >> Terry
&=gt;> >>
>> >>Essentially, we want our product listing page to do
>>the
&g=t;> >>following:
>>>>
>> >> Group all the items that are in stock first=, out of
>> >>stocksecond.
>> >> Within the in stock items, we want to sort b=y SKU.
>> >>
>>>> Right now, since in stock is the actual number in
>>st=ock,
>> >>it is
>>>> sorting by actual number, not just by what is in
>>sto=ck
>> >>and not in
>>>> stock.
>> >>
>> >> -----------
=>> >> Ki Song
>>>>
>> >> On Tue, Aug 4, 2009 at 2:13 PM, Govinda
=>> >><<mailto:govinda.webdnatalk@gmail.com
>>>> >govinda.webdnatalk@gmail.com> wrote:
>> >>=
>> >> Ki,
>>>>
>> >> I don't think so.
>> >>
&=gt;> >> But with webdna you don't needit either. If you are
>> >>not able to do
>> >=> what you want, then post the problem,someone will
>> >>surely guide you
>> >> to= the solution.
>> >>
>>>>
>> >> On Aug 4, 2009, at 12:07 PM, Ki Song -
=>>Knifecenter.com
>>>>wrote:
>> >>
>> >> Is something lik=e this possible in a searchcontext:
>> >>
>> >> &asSKUsort=3D2&=;deON HANDsort=3D1&ON HANDtype=3Dbool
>>>>
>> >> Can a data type be type boolean in a search= context?
>> >>
>>>> -----------
>> >> Ki Song
>> >>
>> >>
>> >>------------
>> >> John Butler (Govinda)
>> >&=gt;
>><mailto:govinda.webdnatalk@gmail.com>govinda.webdna=talk@gmail.com
>>>>
>> >>
>> >>
>> >> <=br>>>---------------------------------------------------------
&=gt;>>> This message is sent to you because you are
>>subscrib=ed
>> >>to
>> >>the mailing list
>> >><<mailto:talk@webdna.us>tal=k@webdna.us>.
>> >> Tounsubscribe, E-mail to:
>> >><<mailto:talk-leave@web=dna.us>talk-leave@webdna.us
>>>> >
>> >> archives:
>> >><http=://mail.webdna.us/list/talk@webdna.us>http://mail.webdna.us/list/talk@=webdna.us
>>>> old archives:
>> >><http://dev.webdna.us/TalkL=istArchive/>http://dev.webdna.us/TalkListArchive/
>>>>
>> >>
>> >> --
>> >>=; Terry Wilson | terry@terryfic.com |
>>http://terryfic.com
>> >> http://WhosComing.co=m - a simplified, affordable
>>online
>> >>reservation
>> >> s=ystem
>> >>http://TightJacket.com -- stylish protection for your
>> >>=;laptop
>> >>
>>-------------------------------------------------------------------------=-
>> >> Attitude is the onlydifference between ordeal and
>> >>adventure.
>> =>>
>>----------------------------------------------------=-----
>>>> This message is sent to you because you are
>>subscrib=ed
>> >>to
>> >>the mailing list <talk@webdna.us>.
>> >> To unsubscr=ibe, E-mail to: <talk-leave@webdna.us>
>>>> archives: http://mail.webdna.us/list/talk@webdna.us
>> =>> old archives:http://dev.webdna.us/TalkListArchive/
>> >
>>
>=;>
>
=A0