Jump to content

Recommended Posts

Iuno how to explain but i can show u visually..

 

 

if it's anything below 10 it should equal 1.

 

anything between 10 and 19 should equal 2.

 

anything between 20 29 should equal 3..

 

any so on..

 

 

If u may ask why i need this? it's cause im creating custom forum software, and im on the part were u add a reply and it goes to the last page if needed. lloll long story short.

 

Link to comment
https://forums.phpfreaks.com/topic/186151-i-need-to-round-my-variable/
Share on other sites

sounds like a pagination system

http://www.phpfreaks.com/tutorial/basic-pagination a tutorial here

 

no i alrdy know that, lol

im just saying i echo out a variable let's say 38.

 

i need that to be SET TO 3.

 

IF the variable is 200 i need it to be set to 20

 

just basic rounding but iuno how.

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.