[FX.php List] MacRoman extended characters

Gjermund Gusland Thorsen ggt667 at gmail.com
Sat Nov 18 03:00:18 MST 2006


The clue is as long as you use FileMaker 7 or newer to newer convert
any strings really
make sure you have this tag in your header:

<meta http-equiv="content-type" content="text/html;charset=UTF-8">

then conversion should be obsolete

ggt667

2005/10/10, Dennis Crall <dennis-crall at uiowa.edu>:
>
> Marisa,
>
> My situation involved a search and foreign language characters, so you may
> have to experiment a bit. But here is what I did:
>
> $fx->AddDBParam( $key, utf8_encode( $value ), "eq" );
>
> utf8_encode() translates $value into a unicode string, which is how
> FileMaker wants to store the data. So I would make sure that any data you
> post through the form is encoded as UTF8. I don't believe you need to decode
> data coming back from the database.
>
> This method assumes utf8_encode() knows how to translate MacRoman strings,
> which I'm not sure about.
>
> Best of luck,
>
> Denny
>
>
>
> On 10/10/05 11:56 AM, "Marisa Smith" <marisa at datasmithconsulting.net> wrote:
>
> > Dennis - would you mind giving more details about how you did this?  I just
> > spent 2 hours working on the exact same problem as Kevin and have yet to
> > figure it out.  I tried changing the character set to UTF-8 on the page,
> > which helped - the data is now written back to the database, whereas before
> > none of the data in the form would get written back.
> >
> > Now, if I display the data stored in the field it works fine --EXCEPT if I
> > try to display it in a textarea form field.  In this case, it displays
> > &#8217; in the form field among the rest of the field contents, and if I
> > then submit the form again, and look in the database, the &#8217; is stored
> > in the field instead of the curly apostrophe.
> >
> > Are you encoding/decoding the data before you POST it back to the database?
> > If so, would you mind posting a snippet of your code?  I must be missing
> > something simple.
> >
> > Thanks!
> > Marisa
> >
> >
> >
> > On 10/10/2005 12:07 PM, "Dennis Crall" <dennis-crall at uiowa.edu> wrote:
> >
> >>
> >> I just solved some encoding issue with PHP's utf8_encode().
> >>
> >> http://us3.php.net/manual/en/function.utf8-encode.php
> >>
> >> Not sure it will solve your problem but worth a try.
> >>
> >>
> >> On 10/10/05 10:57 AM, "Kevin Drennan" <kevin at santafe.edu> wrote:
> >>
> >>> I've got a user who managed to break one of my forms by inputing a
> >>> MacRoman smart quote that they pasted from another application. Does
> >>> anyone have a strategy for converting this character to something
> >>> safe? As far as I can tell htmlentitites() doesn't support the
> >>> MacRoman character set.
> >>>
> >>> Thanks,
> >>> Kevin
> >>> _______________________________________________
> >>> FX.php_List mailing list
> >>> FX.php_List at mail.iviking.org
> >>> http://www.iviking.org/mailman/listinfo/fx.php_list
> >>
> >> _______________________________________________
> >> FX.php_List mailing list
> >> FX.php_List at mail.iviking.org
> >> http://www.iviking.org/mailman/listinfo/fx.php_list
> >>
> >>
> >
> > ---------------------------------------------------------------------
> > Marisa Smith, President
> > DataSmith Consulting, LLC
> > 9206 Huron River Drive
> > Dexter, MI 48130
> > Phone: (734) 426-8077
> > Fax: (734) 426-7069 ­ NEW!
> > http://www.datasmithconsulting.net
> > Filemaker Solutions Alliance Associate Member
> >
> >
> > _______________________________________________
> > FX.php_List mailing list
> > FX.php_List at mail.iviking.org
> > http://www.iviking.org/mailman/listinfo/fx.php_list
>
> _______________________________________________
> FX.php_List mailing list
> FX.php_List at mail.iviking.org
> http://www.iviking.org/mailman/listinfo/fx.php_list
>


More information about the FX.php_List mailing list