Re: nested showif?

This WebDNA talk-list message is from

1998


It keeps the original formatting.
numero = 17253
interpreted = N
texte = >>Is there a way to combine [showif] commands? >> >>I have: >>[showif [name]=phone] >> [showif [value]> ] >> ...do something... >> [/showif] >>[/showif| >> >>And I want something which does: >>[showif [name]=phone]-AND-[value]> ] >> ...do something... >>[/showif] > >You're already doing it the right way. If you have lot's of conditions you >could add a simple check function by: > >[Math show=f]EverythingsOK=0[/Math] > >[HideIf [value1]=1][Math show=f]EverythingsOK=EverythingsOK+1[/Math][/HideIf] >[HideIf [value2]=1][Math show=f]EverythingsOK=EverythingsOK+1[/Math][/HideIf] >[HideIf [value3]=1][Math show=f]EverythingsOK=EverythingsOK+1[/Math][/HideIf] > >[ShowIf [Math]EverythingsOK[/Math]0] >Your magic message here >[/ShowIf] This is a great way to get rid of all that nesting, and not only is it faster but it eliminates that Too many nested... error too ... :)Sincerely, Ken Grome 808-737-6499 WebDNA Solutions mailto:ken@webdna.net http://www.webdna.net Associated Messages, from the most recent to the oldest:

    
  1. Re: nested showif? (Kenneth Grome 1998)
  2. Re: nested showif? (christer@ljusaideer.se (Christer Olsson) 1998)
  3. nested showif? (Peter Ostry 1998)
>>Is there a way to combine [showif] commands? >> >>I have: >>[showif [name]=phone] >> [showif [value]> ] >> ...do something... >> [/showif] >>[/showif| >> >>And I want something which does: >>[showif [name]=phone]-AND-[value]> ] >> ...do something... >>[/showif] > >You're already doing it the right way. If you have lot's of conditions you >could add a simple check function by: > >[Math show=f]EverythingsOK=0[/Math] > >[HideIf [value1]=1][Math show=f]EverythingsOK=EverythingsOK+1[/Math][/HideIf] >[HideIf [value2]=1][Math show=f]EverythingsOK=EverythingsOK+1[/Math][/HideIf] >[HideIf [value3]=1][Math show=f]EverythingsOK=EverythingsOK+1[/Math][/HideIf] > >[ShowIf [math]EverythingsOK[/Math]0] >Your magic message here >[/ShowIf] This is a great way to get rid of all that nesting, and not only is it faster but it eliminates that Too many nested... error too ... :)Sincerely, Ken Grome 808-737-6499 WebDNA Solutions mailto:ken@webdna.net http://www.webdna.net Kenneth Grome

DOWNLOAD WEBDNA NOW!

Top Articles:

Talk List

The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...

Related Readings:

Stumpted Again (1997) [Fwd: Rotating Banners ... (was LinkExchange)] (1997) searchable list archive (1997) Location of Webcat site in folder hierarchy (1997) Initiating NewCart (1997) RE: Cookies? (1997) Upgrading old WebCat Database Files (1997) Separate SSL Server (1997) Conveting Characters to Graphics (1997) [CART] (1997) off topic fetch vs PCS photomaster (1997) Emailer error codes (1999) Automatic thumbnail images (1998) ErrorMessages.db suggestion (1997) [isfile] ? (1997) RE: OK, here goes... (1997) WebCat2b13MacPlugIn - More limits on [include] (1997) OS X Line Endings HELL! (2003) Custom Error Pages - what I've done (1998) [OT] SSL security in browser (2005)