Wednesday, April 17, 2013

About PHP / MySQL: Use floor to always round down

If you can't see this email, click here

About

PHP / MySQL

PHP Basics

MySQL Basics

Advanced Skills



From Angela Bradley, your Guide to PHP / MySQL
Hello Programmers

This week we look at another way to round. You can use floor to always round down. So no matter what comes after the decimal point, the number is always rounded down.

Have a great week!


Use floor to always round down
The floor function is used to always round down.  For example:  2.1 and 2.9999999 would both round down to 2.  This is sometimes used because you can't have a fraction... Read more

Use Ceil to always round up
Ceil (short for Ceiling) is used to always round a number up.  So for example, 5.1 and 5.9 would both round up to the number 6 if you were using... Read more

April Fools Day!
All around the world web masters are playing tricks on their readers today.  Its a fun little tradition to play an April fools day joke online.  Did you do something... Read more

Learn MySQL
MySQL is a relational database and a powerful online tool for storing important information and delivering that information back to your website on demand. Here you can learn more about how to use MySQL.

 


Related Searches
Featured Articles
Advanced PHP
PHP with MySQL
Graphics- GD Library
Step By Steps
PHP Functions
MySQL Commands

 

More from About.com

10 Easy Ways to Look Thinner
Don't wait until you've lost those first pounds to make these simple, slimming changes. Read more...>



Create a Shared Photo Stream
Sharing your photo stream with friends and family is a great way to keep in touch. Read more...>




This newsletter is written by:
Angela Bradley
PHP / MySQL Guide
Email Me | My Blog | My Forum
 
Sign up for more free newsletters on your favorite topics
You are receiving this newsletter because you subscribed to the About.com PHP / MySQL newsletter. If you wish to change your email address or unsubscribe, please click here.

About.com respects your privacy: Our Privacy Policy

Contact Information:
1500 Broadway, 6th Floor
New York, NY, 10036

© 2012 About.com
 


Must Reads
Learn PHP
Using PHP with MySQL
Learn MySQL
Create Email Forms
PHP Login Script
 
Follow me on:
Facebook Twitter

Advertisement

No comments:

Post a Comment