[FX.php List] "degrees" symbol
DC
dan.cynosure at dbmscan.com
Wed Dec 20 09:29:57 MST 2006
it sounds like you want to let users type the word degrees and then
store it as a degree symbol in FMP... right?
why would you want to do that? the only reason i can think of is if you
have some users looking at the data in native FMP layouts.
i would think you should just encode the degrees symbol to send it to
FMP through FX.php:
° OR ° OR °
This should do the trick (stores HTML entity in FMP so that when it
comes back out the Web page will show a degree symbol):
> $instructions2 = str_replace("degrees", "°", $instructions);
As an aside...
look at urlencode() to automatically change degree symbol to entity in
PHP. also, look at htmlentities() which also has a charset parameter.
you'd have to use urldecode() AND/OR html_entity_decode() to get it back
to display as a degrees symbol in a web page.
dan
Alex Gates had written:
> Greetings-
>
> I'm doing a string replace to replace the word "degrees" with the
> degrees symbol "°".
> I'm using this code for the string replace:
>
> $instructions = trim($_POST['instructions']);
> $instructions2 = str_replace("degrees", "°", $instructions);
>
>
> It works fine in the PHP and displays correctly on my "please verify"
> page - but when I try to submit this to FileMaker I get:
> Error 958 - Parameter missing in query.
>
> I only get this error if I happen to use the word "degrees." It works
> fine if I don't.
>
> My charset is: iso-8859-1
>
> Any ideas?
>
> Alex P. Gates
>
>
> _______________________________________________
> 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