Oops...didn't see this before I posted.

~Dina


----- Original Message -----
From: "Joshua Miller" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Monday, March 10, 2003 3:52 PM
Subject: RE: Special Characters driving me nuts


> I HAVE to use URLEncodedFormat to store the data. Unfortunately what I
> have to do is allow a preview of the user's submission, but there are
> around 50 fields I have to store that typically go into about 6
> different tables, so I'm storing everything as a name=value;name=value;
> string in a table, displaying the preview and then cleaning out the
> preview table upon submission. So, I'm creating dynamic variables before
> the insert and I have to use URLEncodedFormat so that the users can
> enter the characters I use as delimiters.
>
> Basically, I use name=value;name=value; so if the user enters an = or ;
> character it breaks my string.
>
> This is how I'm doing it right now:
>
> 1. URLEncodedFormat() the data into the database
> 2. Grab that string from the database on the preview page
> 3. Loop over the string and cut into name/value pairs for another list
> loop
> 4. On the second list loop URLDecode the value so it's correct as it was
> entered by the user
> 5. Display using HTMLEditFormat() on the document
>
> This should work just fine and be exactly like storing the data as-is in
> the database. The problem is if the value of a variable on the preview
> page begins with a special character it won't display. Everything else
> around it displays fine and even if there are quotes in the middle they
> work, it's just the first character. If the first character is a special
> character it won't display that entire value.
>
> Any other ideas?
>
> Joshua Miller
> Head Programmer / IT Manager
> Garrison Enterprises Inc.
> www.garrisonenterprises.net
> [EMAIL PROTECTED]
> (704) 569-9044 ext. 254
>
> ************************************************************************
> *************
> Any views expressed in this message are those of the individual sender,
> except where the sender states them to be the views of
> Garrison Enterprises Inc.
>
> This e-mail is intended only for the individual or entity to which it is
> addressed and contains information that is private and confidential. If
> you are not the intended recipient you are hereby notified that any
> dissemination, distribution or copying is strictly prohibited. If you
> have received this e-mail in error please delete it immediately and
> advise us by return e-mail to [EMAIL PROTECTED]
> ************************************************************************
> *************
>
>
> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
> Sent: Monday, March 10, 2003 2:41 PM
> To: CF-Talk
> Subject: Re: Special Characters driving me nuts
>
>
> Don't use URLEncodedFormat() when inserting the data.  Place it into the
> database "as-is".
>
> Use HTMLEditFormat() to display the data.
>
> You'll have to update rows that you URLEncodedFormat() back to their
> original format.
>
> ----- Original Message -----
> From: Joshua Miller <[EMAIL PROTECTED]>
> Date: Monday, March 10, 2003 12:26 pm
> Subject: Special Characters driving me nuts
>
> > Greetings,
> >
> > I've been fighting with user-input and special characters for days
> > now,I'm starting to get really frustrated.
> >
> > Here's the scenario:
> >
> > 1. User enters data into a textarea field. This will usually contain
> > several special characters (?/{}[]|\">[EMAIL PROTECTED] <')" >mailto:[EMAIL 
> > PROTECTED]&*,>
> > &*,<>?/{}[]|\-_+)(^)
> > 2. I use URLEncodedFormat before sticking the data in my database
> > table,so I'm storing encoded data
> > 3. I use URLDecode when retrieving the data into an HTML page to show
> > the data entered.
> >
> > Here's the problem:
> >
> > Data that begins with a special character doesn't display. Data
> > that is
> > surrounded by " marks doesn't display
> > For example:
> >
> > "This" line won't display in HTML
> > This line $ will display in HTML
> > This line "will not" display in HTML
> > $This line will not display in HTML
> >
> > If I use HTMLEditFormat() I still can't see the items surrounded
> > by "
> > marks and it also displays the URLEncodedFormat information so
> > space =
> > %20 on screen in the HTML page.
> >
> > How do I overcome this issue?
> >
> > Thanks,
> >
> > Joshua Miller
> > Head Programmer / IT Manager
> > Garrison Enterprises Inc.
> > www.garrisonenterprises.net <"
> > target="l">http://www.garrisonenterprises.net/>
> > [EMAIL PROTECTED]
> > (704) 569-9044 ext. 254
> >
> > **********************************************************************
> > **
> > *************
> > Any views expressed in this message are those of the individual
> > sender,except where the sender states them to be the views of
> > Garrison Enterprises Inc.
> >
> > This e-mail is intended only for the individual or entity to which
> > it is
> > addressed and contains information that is private and
> > confidential. If
> > you are not the intended recipient you are hereby notified that any
> > dissemination, distribution or copying is strictly prohibited. If
> > you
> > have received this e-mail in error please delete it immediately and
> > advise us by return e-mail to
> > <')" >mailto:[EMAIL PROTECTED]>
> > [EMAIL PROTECTED]
> >
> ************************************************************************
> > *************
> >
> >
> >
>
> 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Get the mailserver that powers this list at http://www.coolfusion.com

                                Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
                                

Reply via email to