Ask a Question related to Coldfusion - Advanced Techniques, Design and Development.
-
Newyork_az #1
Replace(#message#, '#', '##') - Why error?
<!--- MESSAGE is generated by online visual html editor in this format (message
- <font color="#FF0000">hello word</font>) --->
<!---I do the following --->
<cfset message = JSStringFormat(#message#)>
<!--- Now MESSAGE in this format (message - <font color=/"#FF0000/">hello
word</font>) --->
<!--- Next i want --->
<cfoutput>#message#</cfoutput>
<!--- But I receive a mistake Because of - # - --->
<!---I do the following --->
<cfset message=Replace(#message#, '#', '##')>
<!--- But I receive a mistake too --->
How competently to make replacement in my case??
Newyork_az Guest
-
How To Supress Acrobat Error Message And Alert Message
Is there any way to supress those pop up message? If can't, is there any way to catch it? -
Error Message When Sending Message In Windows Mail
Am I the only one getting an error message when replying to a posted message using Windows Mail. Every time I send a message I get a popup error... -
Error Message "A drawing error ocurrred which is probably due to an out-of-memory condition. Try qu
I am running Acrobat Reader 5.0 on a Mac Powerbook running OS 9.2 and keep getting "A drawing error occurred which is probably due to an out of... -
Search and replace (super global replace)
I am using the 30 day trail of acrobate professional....before I buy it I have a few questions.... 1) is there a "search and replace" function... -
syntax error in replace statement
What's wrong with this code? strLongDesc = Replace(Replace(Replace(Replace(Trim(Request.Form("LongDesc")),"'","''"),vbC... -
aminz #2
Re: Replace(#message#, '#', '##') - Why error?
Put your #message# in double quotes like so ...
"#message#"
that should correct the problem
aminz Guest
-
OldCFer #3
Re: Replace(#message#, '#', '##') - Why error?
Try:
<cfset message=Replace(#message#, '##', '####')>
OldCFer Guest
-
Newyork_az #4
Re: Replace(#message#, '#', '##') - Why error?
Thanks for advice
Well whereas to be here?
<cfset message=Replace("<font color=#FF0000>hello word</font>", '##', '####')>
How to make replacement then to draw a conclusion without mistakes
If already at replacement the mistake leaves?
Newyork_az Guest
-
Adam Cameron #5
Re: Replace(#message#, '#', '##') - Why error?
> <cfset message=Replace("<font color=#FF0000>hello word</font>", '##', '####')>
Simple rule in CF.
In a CF statement, if you're using a # symbol literally (ie: not in the CF
"evaluate as a variable" sense, but just as the # character), then you have
to escape it.
So you'd need to do this:
<cfset message=Replace("<font color=##FF0000>hello word</font>", '##',
'####')>
Otherwise you're telling CF: "evaluate the expression that is
#FF0000>hello word</font>", '#
Which obviously doesn't make sense.
I can't make out from what you've posted what you're actually trying to
achieve here.
Don't tell us a story, just post the actual code.
--
Adam
Adam Cameron Guest
-
Newyork_az #6
Re: Replace(#message#, '#', '##') - Why error?
You cannot understand that this line <font color = #FF0000> hello word</font>
is generated by Online visual html editor
and I cannot change in it in manual.
I need to make replacement with program way.
There is a decision?
Newyork_az Guest



Reply With Quote

