Forum Moderators: coopster
Good attitude on your part -- you had fun, and that kind of thing is good practice, even if the function already exists.
In the USA we use commas to denote thousands, and then million . billions ..
In Western Europe, they use the decimal point (dot) the same way we use the comma.
For example:
In Germany or France, one might write "I made 11.275 Euros last month.:
They guy did well in Euros, but that's only 14 bucks in the USA.
Quick now! Is the following number less than a billion or more than a billion?
1000000000
I can't tell myself, full of beer and having misplaced my glasses.
I had two cold glasses of bier, I probably left one or the other in the can.
The French and Germans would use commas like everybody else if they
weren't trying to save ink money. Don't get me started on the English. -Larry
There's this wonderful site some of you may have heard of called Google [google.com] that will let you (get this) search for things on a website! Who knows how they plan to make any money on it, but it's great for searching the PHP documentation! ;)
(tongue firmly and "good-naturedly" planted in cheek)
then you look through the manual [php.net] for what type of data you are dealing with and read through the functions available until you find something that might work.
I know it takes a lot of time but it will help you a lot in the future as to understanding all of the things you can do. You may just have that "I think I remember seeing a function for that..." moment. ;)
I often read through the main pages for strings, arrays, math, mysql, among many others. It helps figure out what new functions might be available in any given release, as well as giving you a look at functions you may not have seen before because they are not often used.
I highly recommend that people spend some of their free time doing this, it shortens the learning curve more than you could ever imagine.
</OT>
There's this wonderful site some of you may have heard of called Google that will let you (get this) search for things on a website! Who knows how they plan to make any money on it, but it's great for searching the PHP documentation! ;)(tongue firmly and "good-naturedly" planted in cheek)
I usually do use google when looking for functions, and I'll usually google "string functions" or whatever category the function would be in. Either that or I'll find a function that is in that category if I don't know the name of the category and then look through the similar functions list on the left. However, there are times when I can't find the function I'm looking for or I just skip over the function I'm looking for (especially when I'm working late at night or after diving practice :P).
Like sonjay said, I've learned from making the function and I've now had the importance of the php manual to saving me time emphasized. I also have a function for my calculator to help me get some sleep in class :)