RE: Using reReplace Backreference as StructKey or Argument

2007-11-16 Thread Ben Nadel
MX7 Developer www.bennadel.com Need ColdFusion Help? www.bennadel.com/ask-ben/ -Original Message- From: Jon Clausen [mailto:[EMAIL PROTECTED] Sent: Thursday, November 15, 2007 8:17 PM To: CF-Talk Subject: Re: Using reReplace Backreference as StructKey or Argument Ben, Thanks

Re: Using reReplace Backreference as StructKey or Argument

2007-11-16 Thread Jon Clausen
Nadel Certified Advanced ColdFusion MX7 Developer www.bennadel.com Need ColdFusion Help? www.bennadel.com/ask-ben/ -Original Message- From: Jon Clausen [mailto:[EMAIL PROTECTED] Sent: Thursday, November 15, 2007 8:17 PM To: CF-Talk Subject: Re: Using reReplace Backreference

RE: Using reReplace Backreference as StructKey or Argument

2007-11-16 Thread Ben Nadel
reReplace Backreference as StructKey or Argument Ben, Agreed, the Len/Pos array loops are ugly and a pain to deal with. Hence my attempts to bypass all of that by finding a way to pass the backreference directly in reReplace... :-) Got around to running timers comparing reFind and your

RE: Using reReplace Backreference as StructKey or Argument

2007-11-15 Thread Ben Nadel
Clausen [mailto:[EMAIL PROTECTED] Sent: Wednesday, November 14, 2007 8:40 PM To: CF-Talk Subject: Using reReplace Backreference as StructKey or Argument I'm sure it's something simple that I'm missing, but I want to use a regex backreference as the struct key (i.e. - struct[key]) or as an argument

Re: Using reReplace Backreference as StructKey or Argument

2007-11-15 Thread Ben Doom
Sorry, you can't do that. Here's why: Coldfusion hands strings off to the regex engine. CF allows you to used functions, variables, etc. in the string, but it executes them *before* the regex runs. So, in your first code sample, it's trying to find the literal key \1 in appSettings, and

Re: Using reReplace Backreference as StructKey or Argument

2007-11-15 Thread Jon Clausen
Clausen [mailto:[EMAIL PROTECTED] Sent: Wednesday, November 14, 2007 8:40 PM To: CF-Talk Subject: Using reReplace Backreference as StructKey or Argument I'm sure it's something simple that I'm missing, but I want to use a regex backreference as the struct key (i.e. - struct[key

Re: Using reReplace Backreference as StructKey or Argument

2007-11-15 Thread Jon Clausen
Ben, Thanks for the reply. I had sent a response to Ben's reply earlier today, but I guess it didn't go through. I figured the order of execution was the issue. I was hoping for a way to trick the execution order and tried writing the function call in a bunch of different ways other than

Using reReplace Backreference as StructKey or Argument

2007-11-14 Thread Jon Clausen
I'm sure it's something simple that I'm missing, but I want to use a regex backreference as the struct key (i.e. - struct[key]) or as an argument (i.e. - function(argument) ) but I've failed in all my attempts so far. For now I've written the code out using a loop with reFind(),