Re: weening me off overwriting form variables. John Peacock?
This WebDNA talk-list message is from 2000
It keeps the original formatting.
numero = 36517
interpreted = N
texte = I don't remember Joe,but (and maybe this is obvious)You now can simply check if a var has not been passed in and then initialize it with[text][showif [url][myVar][/url]=[url][raw][myVar][/raw][/url]][text]myVar=what_I_have_been_assigning_since_webcat3[/text][/showif]You could write an include that goes thru a list of vars (a list you stick in theinclude tag itself ...&initialize=var1,var2,var3])and use listwords and a modified version of the above within the listwords toinitialize all those vars (assuming all need to equal null, or some common value.)Or why not simply use [textsecure=F]myVar=somevalueWhichYouCanStillOverrideEvenWithWebcat4[/text]since that is now an official documented feature (It is only NOT RECOMMENDED by SMbecause newbies might shoot themselves in the foot with it - ie using an insecure varto determine authorized access, etc.)(which reminds me, maybe this is what you were asking for in the 1st place:+++++++++++++++++++I nearly forgot, you need to escape the & in the replace string, otherwise it doesn't work right. That makes itSearch: \[text ([^\]]#)\] or \[text ([^]]*)\] (for BBEdit)Replace: \[text \0\&secure=f\]John PeacockJohn Peacock wrote:>> The string [^\]] (or [^]] apparently under BBEdit) is a negative set.> It will match every character that is not in the set, that is to say,> anything not a right bracket. Whether you have to escape the ] in the> expression is based on the exact implementation. I just tested it in> MultiEdit with the various example strings you (and others) included,> and discovered that MultiEdit will die screaming if you do not escape> the ], but that my search strings worked like I designed them.>> I can also highly recommend the O'Reilly RegEx book. One of the things> about Perl especially is that after enough experience with regex, you> discover that almost everything can be fixed with the correct regex.>> HTH>> John Peacock>> Kenneth Grome wrote:> >> > >On 5/3/00 3:55 pm, Jereme Claussen so noted...> > >> > >>BBEdit has an option titled Use Grep which uses standard RegEx for> > >>those concerned..> > >>> > >>>Or if you have an editor with regex support, you can make two passes:> > >>>> > >>>Search: \[text ([^\]]#)\]> > >>>Replace: \[text \0&secure=f\]> > >> > >Slight modifications are needed for BBEdit Lite 4.6 (and I assume BBEdit> > >as well):> > >> > >Search: \[text ([^]]*)\]> > >Replace: \[text \1\&secure=f\]> >Joseph D'Andrea wrote:> In anticipation of someday installing the WebCat 4 we purchased way> back when... I need to remove the coding technique where we relied> on eing able to overwrite incoming form variables. You know, the> technique where you set text variables with the same name as incoming> form variables to empty so you can display input forms pretty.>> I think John Peacock, or someone, posted a solution to this problem> that I have since lost. I tried searching the archives, but haven't> found it yet.>> Does anyone remember the solution that John posted?>> John?>> Thanks,> ___Joe___> _________________________________________________> Joseph D'Andrea JoeDan@West21.com> WEST21.com Internet services for the 21st Century> http://www.west21.com/> _________________________________________________>>-------------------------------------------------------------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:
I don't remember Joe,but (and maybe this is obvious)You now can simply check if a var has not been passed in and then initialize it with[text][showif [url][myVar][/url]=[url][raw][myVar][/raw][/url]][text]myVar=what_I_have_been_assigning_since_webcat3[/text][/showif]You could write an include that goes thru a list of vars (a list you stick in theinclude tag itself ...&initialize=var1,var2,var3])and use listwords and a modified version of the above within the listwords toinitialize all those vars (assuming all need to equal null, or some common value.)Or why not simply use [textsecure=F]myVar=somevalueWhichYouCanStillOverrideEvenWithWebcat4[/text]since that is now an official documented feature (It is only NOT RECOMMENDED by SMbecause newbies might shoot themselves in the foot with it - ie using an insecure varto determine authorized access, etc.)(which reminds me, maybe this is what you were asking for in the 1st place:+++++++++++++++++++I nearly forgot, you need to escape the & in the replace string, otherwise it doesn't work right. That makes itSearch: \[text ([^\]]#)\] or \[text ([^]]*)\] (for BBEdit)Replace: \[text \0\&secure=f\]John PeacockJohn Peacock wrote:>> The string [^\]] (or [^]] apparently under BBEdit) is a negative set.> It will match every character that is not in the set, that is to say,> anything not a right bracket. Whether you have to escape the ] in the> expression is based on the exact implementation. I just tested it in> MultiEdit with the various example strings you (and others) included,> and discovered that MultiEdit will die screaming if you do not escape> the ], but that my search strings worked like I designed them.>> I can also highly recommend the O'Reilly RegEx book. One of the things> about Perl especially is that after enough experience with regex, you> discover that almost everything can be fixed with the correct regex.>> HTH>> John Peacock>> Kenneth Grome wrote:> >> > >On 5/3/00 3:55 pm, Jereme Claussen so noted...> > >> > >>BBEdit has an option titled Use Grep which uses standard RegEx for> > >>those concerned..> > >>> > >>>Or if you have an editor with regex support, you can make two passes:> > >>>> > >>>Search: \[text ([^\]]#)\]> > >>>Replace: \[text \0&secure=f\]> > >> > >Slight modifications are needed for BBEdit Lite 4.6 (and I assume BBEdit> > >as well):> > >> > >Search: \[text ([^]]*)\]> > >Replace: \[text \1\&secure=f\]> >Joseph D'Andrea wrote:> In anticipation of someday installing the WebCat 4 we purchased way> back when... I need to remove the coding technique where we relied> on eing able to overwrite incoming form variables. You know, the> technique where you set text variables with the same name as incoming> form variables to empty so you can display input forms pretty.>> I think John Peacock, or someone, posted a solution to this problem> that I have since lost. I tried searching the archives, but haven't> found it yet.>> Does anyone remember the solution that John posted?>> John?>> Thanks,> ___Joe___> _________________________________________________> Joseph D'Andrea JoeDan@West21.com> WEST21.com Internet services for the 21st Century> http://www.west21.com/> _________________________________________________>>-------------------------------------------------------------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/
John Butler
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:
WebCat b13 CGI -shownext- (1997)
[convertChars] and HTML Tags (1997)
[WebDNA] JSONStore Levels (2020)
search question (2001)
Mixing and/or in searches (1998)
Where is the bug fix info for 4.0.1? (2000)
greater than or equal to (1997)
WC Database Format (1997)
Re[2]: New syntax feedback for 4.0 (2000)
[WebDNA] Still having problems (2008)
Duplicates (1998)
Fun with dates (1997)
Add command creates new cart but I'm passing existing cart...? (2000)
Error: Permision deny. (2005)
Re:Emailer and encryption (1997)
Forcing Paragraph Breaks on Results (1998)
[if] and [showif] - A solution (2002)
Practice runs ? (1997)
texta,b,c,d,e (urgent) (2003)
Part Html part WebDNA (1997)