Reply to Re: "\90" != chr(90)

Your name:

Reply:


Posted by Mara Guida on 10/11/59 11:36

yawnmoth wrote:
> Obviously, "\9" equals chr(9), but what would equal chr(90)? "\90"
> doesn't. Rather, "\90" seems to be equal to chr(9).chr(0). So what
> could I do to get chr(90) using escaped numbers?

You can't do it with numbers in base 10.
You can do it with numbers in base 8 or 16.

http://www.php.net/manual/en/language.types.string.php

$s_b16 = "\x5a";
$s_b8 = "\132";
$s_90 = chr(90);
/* all these strings are equal */

$s_x90 = "\90";
$s_d90 = chr(9*16+0); /* chr(144) */

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация