Log in

View Full Version : How to use number_format() on post total, etc?


TWTCommish
05-22-2001, 08:16 PM
You saw the thread title. :) How can I use the number_format() function on values such as the total number of posts on the forum home page? I tried including a line like this in the phpinclude template...

$totalposts = number_format($totalposts);

...but it didn't work. I tried giving it it's own name ($total_posts), but that didn't work either. Do I simply need to modify the actual source code of the files? I can do this if I need to, but would obviously rather avoid it if possible.

JamesUS
05-23-2001, 04:24 AM
Yes I think you have to change the actual code. Reason being that the phpinclude template is executed before the $totalposts variable has been set.