div a modulo in php

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
User avatar
pelegk2
Forum Regular
Posts: 633
Joined: Thu Nov 27, 2003 5:02 am
Location: Israel - the best place to live in after heaven
Contact:

div a modulo in php

Post by pelegk2 »

i waned to to div and mod calcultaions
i tried to use :
gmp_div
gmp_mod
but i ma getting the message :
Call to undefined function: gmp_div()
what to do?
is there anotherway i can calculate the div and mod?
thanks in advance
peleg
User avatar
patrikG
DevNet Master
Posts: 4235
Joined: Thu Aug 15, 2002 5:53 am
Location: Sussex, UK

Post by patrikG »

Check on the operators section in the manual:

http://uk.php.net/manual/en/language.op ... hmetic.php

The modulus is %
Post Reply