Re: [if] and [showif] - A solution
This WebDNA talk-list message is from 2002
It keeps the original formatting.
numero = 45214
interpreted = N
texte = OK, managed to figure out a solution (without losing too much hair!)[text show=f]ARIN_lookup=[MiddleStartAfter=
&EndBefore=
][TCPConnect host=ws.arin.net][TCPSend]GET /cgi-bin/whois.pl?queryinput=212.240.96.24HTTP/1.0[UnURL]%0D%0A%0D%0A[/UnURL][/TCPSend][/TCPConnect][/middle][/text][showif [ARIN_lookup]^RIPE]Yes[/showif][if [url][ARIN_lookup][/url] ^ RIPE][then]Yes[/then][else]No[/else][/if] **** ******[ARIN_lookup]Not sure why [if] requires the variable to be wrapped in [url], but thisseems to now work.on 13/11/02 3:47 pm, Mark Derrick at mark.derrick@computerwarehouse.co.ukwrote:> These both work for me too, Setting the variable locally seems to be OK, the> problem seems to arise when it's a [TCPConnect] that's creating the contents> of the variable.> > > on 13/11/02 3:33 pm, Dan Strong at webdna@stronggraphicdesign.com wrote:> >> FWIW, the code below works for me on win98/PWM/WC4.0.2.rc2 *AND*>> OSX/Apache1.3.19/WC4.0.2.rc2>> -Dan>> >> On Wed, 13 Nov 2002 07:24:14 -0800>> Dan Strong
wrote:>>> Hmmm, flush your cache maybe?>>> >>> [text show=f]ARIN_lookup=blah_RIPE_blah[/text]>>> [showif [ARIN_lookup]^RIPE]Yes[/showif]>>> [if (([ARIN_lookup]) ^ (RIPE))]>>> [then]Yes[/then]>>> [else]No[/else]>>> [/if]>>>
>>> Also tried :>>> [showif [ARIN_lookup]^RIPE]Yes[/showif]>>> [if (([ARIN_lookup])^(RIPE))]>>> [then]Yes[/then]>>> [else]No[/else]>>> [/if]>>> >>> Returns:>>> ------------->>> Yes Yes>>> Also tried : Yes Yes>>> >>> -Dan>>> ------------------------------------------------------------>>> http://www.StrongGraphicDesign.com>>> (208) 319-0137 | Toll-free p/f 877-561-1656>>> ------------------------------------------------------------>>> NEW! Do-It-Yourself Printing: http://sgd.cceasy.com>>> >>> >>> On Wed, 13 Nov 2002 15:12:48 +0000>>> Mark Derrick wrote:>>>> Still getting Yes and no>>>> >>>> [showif [ARIN_lookup]^RIPE]Yes[/showif]>>>> [if (([ARIN_lookup]) ^ (RIPE))][then]Yes[/then][else]No[/else][/if]>>>> >>>> Also tried :>>>> >>>> [showif [ARIN_lookup]^RIPE]Yes[/showif]>>>> [if (([ARIN_lookup])^(RIPE))][then]Yes[/then][else]No[/else][/if]-------------------------------------------------------------This message is sent to you because you are subscribed to the mailing list .To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://search.smithmicro.com/
Associated Messages, from the most recent to the oldest:
OK, managed to figure out a solution (without losing too much hair!)[text show=f]ARIN_lookup=[MiddleStartAfter=&EndBefore=
][TCPConnect host=ws.arin.net][tcpsend]GET /cgi-bin/whois.pl?queryinput=212.240.96.24HTTP/1.0[unurl]%0D%0A%0D%0A[/UnURL][/TCPSend][/TCPConnect][/middle][/text][showif [ARIN_lookup]^RIPE]Yes[/showif][if [url][ARIN_lookup][/url] ^ RIPE][then]Yes[/then][else]No[/else][/if] **** ******[ARIN_lookup]Not sure why [if] requires the variable to be wrapped in [url], but thisseems to now work.on 13/11/02 3:47 pm, Mark Derrick at mark.derrick@computerwarehouse.co.ukwrote:> These both work for me too, Setting the variable locally seems to be OK, the> problem seems to arise when it's a [tcpconnect] that's creating the contents> of the variable.> > > on 13/11/02 3:33 pm, Dan Strong at webdna@stronggraphicdesign.com wrote:> >> FWIW, the code below works for me on win98/PWM/WC4.0.2.rc2 *AND*>> OSX/Apache1.3.19/WC4.0.2.rc2>> -Dan>> >> On Wed, 13 Nov 2002 07:24:14 -0800>> Dan Strong wrote:>>> Hmmm, flush your cache maybe?>>> >>> [text show=f]ARIN_lookup=blah_RIPE_blah[/text]>>> [showif [ARIN_lookup]^RIPE]Yes[/showif]>>> [if (([ARIN_lookup]) ^ (RIPE))]>>> [then]Yes[/then]>>> [else]No[/else]>>> [/if]>>>
>>> Also tried :>>> [showif [ARIN_lookup]^RIPE]Yes[/showif]>>> [if (([ARIN_lookup])^(RIPE))]>>> [then]Yes[/then]>>> [else]No[/else]>>> [/if]>>> >>> Returns:>>> ------------->>> Yes Yes>>> Also tried : Yes Yes>>> >>> -Dan>>> ------------------------------------------------------------>>> http://www.StrongGraphicDesign.com>>> (208) 319-0137 | Toll-free p/f 877-561-1656>>> ------------------------------------------------------------>>> NEW! Do-It-Yourself Printing: http://sgd.cceasy.com>>> >>> >>> On Wed, 13 Nov 2002 15:12:48 +0000>>> Mark Derrick wrote:>>>> Still getting Yes and no>>>> >>>> [showif [ARIN_lookup]^RIPE]Yes[/showif]>>>> [if (([ARIN_lookup]) ^ (RIPE))][then]Yes[/then][else]No[/else][/if]>>>> >>>> Also tried :>>>> >>>> [showif [ARIN_lookup]^RIPE]Yes[/showif]>>>> [if (([ARIN_lookup])^(RIPE))][then]Yes[/then][else]No[/else][/if]-------------------------------------------------------------This message is sent to you because you are subscribed to the mailing list .To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://search.smithmicro.com/
Mark Derrick
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:
Hierarchy of form/text/math variables (2000)
[quantity] within formulas (1997)
WebCatalog sales (1997)
Hideifs / Showifs (2000)
Pithy questions on webcommerce & siteedit (1997)
attaching a file using [sendmail]? (2002)
Re:Variable Math (1998)
Hello??? (1997)
WebCat2b13 Mac plugin - [sendmail] and checkboxes (1997)
Help with Repost Data msg from form (1997)
WebCatalog for Mac 2.0.1 Released (1997)
Make sure I understand this??? (1997)
Re[2]: Enhancement Request for WebCatalog-NT (1996)
GuestBook example (1997)
Plugin or CGI or both (1997)
Commitdatabase tag (1998)
Configuring E-mail (1997)
WebCatalog security on NT (2000)
Spawning Holdup? (2000)
USPS - SiteBuilder (2005)