Forum FAQForum FAQSearchSearch MemberlistMemberlist Forum ignore listForum ignore list RegisterRegister ProfileProfile Log in to check your private messagesLog in to check your private messages Log inLog in
php i matematika :-/

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    mi3dot.org Forum Index -> Server-side
View previous topic :: View next topic  
Author Message
_butch



Joined: 10 Sep 2003
Posts: 870
Location: Maichno, Krlovc

PostPosted: 31.01.2004 20:38    Post subject: php i matematika :-/ Add user to your forum ignore list Reply with quote

dakle, ovako ->
izvadim sadasnji rating iz baze i broj glasova, pomnozim rating sa glasovima, zbrojim pomnozeni rating sa ratingom koji je unesen, povecam broj glasova za 1 i rating podijelim sa tim brojem glasova i dobijem novi rating..
sada mi je problem kada je zbroj 2 ratinga neki neparan broj..
primjer -> 11 / 3 = 4
sada mi to nije jasno.. mora biti 3.6666, a u bazu mi ga ubaci 4 cisto..

jel mozda koncept krivi il nes ?
mislim..

_________________
FRENCH GUARD: No chance, English bed-wetting types.
I burst my pimples at you and call your door-opening request a silly thing, you tiny-brained wipers of other people's bottoms!
Flikrac
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
blackduke
mi3.crew


Joined: 08 Sep 2003
Posts: 2681
Location: Zagreb

PostPosted: 31.01.2004 20:50    Post subject: Add user to your forum ignore list Reply with quote

mozda ti je varijabla definirana sa integerom a treba bit real
ili koristis div i mod umjesto /

cek, to je u pascalu HELLO MR. SCIENTIST!!!111
Back to top
View user's profile Send private message Visit poster's website Twitter profile
ivan



Joined: 08 Sep 2003
Posts: 320
Location: Zagreb

PostPosted: 31.01.2004 21:14    Post subject: Add user to your forum ignore list Reply with quote

kako stari paskalaš kaže, najvjerovatnije si definirao to polje u bazi kao integer

_________________
no ojro
Back to top
View user's profile Send private message Visit poster's website
che.UP
mi3.crew


Joined: 07 Sep 2003
Posts: 2320
Location: zagreb

PostPosted: 31.01.2004 22:36    Post subject: Add user to your forum ignore list Reply with quote

ziher je to, stavi si double ili float, ovisi kaj ti treba...

_________________
UP | TypeTester | Accommodations App
Meni u Firefox-u ne radi AJAX
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    mi3dot.org Forum Index -> Server-side All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group