PDA

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


TWTCommish
22 May 2001, 21:16
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...



Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------



...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
23 May 2001, 05:24
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.