You are here: Re: numeric function « PHP Programming Language « IT news, forums, messages
Re: numeric function

Posted by Alvaro G Vicario on 05/23/05 12:53

*** Davide wrote/escribió (23 May 2005 02:46:16 -0700):
> I've got 4.7554844644e+06 and I need to have 4.7Mbits
> Is there a php function can helps me?

1 byte = 8 bits
1024 bytes = 1 kilobyte (or KB)
1024 kilobytes = 1 megabyte (or MB)

You need to convert from an unknown unit to megabits. Let's suppose the
unknown unit is bits:

$result= 4.7554844644e+06 / (1024*1024);

If they aren't bits, do the math accordingly.


--
-- Álvaro G. Vicario - Burgos, Spain
-- http://bits.demogracia.com - Mi sitio sobre programación web
-- Don't e-mail me your questions, post them to the group
--

 

Navigation:

[Reply to this 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

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