FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » pgsql and exception
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: pgsql and exception [message #178118 is a reply to message #178116] Mon, 14 May 2012 13:26 Go to previous messageGo to previous message
Une Bvue is currently offline  Une Bvue
Messages: 30
Registered: March 2012
Karma:
Member
On 14/05/12 14:56, M. Strobel wrote:
> how about substr()?
right I'm testing that however I'm not sure it works with accentuated
(UTF-8) characters.

for example with :
--- code ---------------------------------------------------------------
<?php
header('Content-Type:text/html; charset=utf-8');

$str="Etre ou ne pas etre, telle est est la question.";
echo $str."<br />";
echo strlen($str)."<br />";
echo substr($str, 0, 16)."<br />";

$str="Être ou ne pas être, telle est est la question."; // Accentuated
echo $str."<br />";
echo strlen($str)."<br />";
echo substr($str, 0, 16)."<br />";

?>
------------------------------------------------------------------------

I get :
Etre ou ne pas etre, telle est est la question.
47
Etre ou ne pas e
Être ou ne pas être, telle est est la question.
49
Être ou ne pas


no ending "e" with accentuated chars.
not detrimental, obviously.
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic:
Next Topic: Re: reading a newline from a properties file
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Sun Nov 24 13:54:57 GMT 2024

Total time taken to generate the page: 0.04958 seconds