Previous Thread
Next Thread
Print Thread
Hop To
Joined: Jan 2009
Posts: 22
W
stranger
stranger
W Offline
Joined: Jan 2009
Posts: 22
Hello. I was hoping someone might help me.

I wish to change the number shown on the site for the "max online" number along with the date but am having trouble working out how to do that. (The number there now is too large due to some attack on our forums and so I want to reduce it back to what it was which was more realistic).

Can anyone point me in the right direction?

Thank you very much.

Joined: Dec 2003
Posts: 6,566
Likes: 78
Joined: Dec 2003
Posts: 6,566
Likes: 78
The data is stored in the table named cache
max_online field just change to what you want
max_online_timestamp field Not sure what format is used to change the date


Blue Man Group
There is no such thing as stupid questions. Just stupid answers
Joined: Jan 2009
Posts: 22
W
stranger
stranger
W Offline
Joined: Jan 2009
Posts: 22
Thanks for that,.,... but I need a bit more hand-holding.... how/where do I do that?

smile

Joined: Dec 2003
Posts: 6,566
Likes: 78
Joined: Dec 2003
Posts: 6,566
Likes: 78
okay it is one of the tables in the MYSQL database you setup to use for your forum.
You probably have phpmyadmin as a management tool from your host provider.
Using phpmyadmin open your database select the ubbt_cache table on the left side
I assume you used the default ubbt_ prefix.
Select the browse link at the top left.
Here you see the data.
Select the pencil icon to the left of max_online to edit that value.
change the cache_value number to what you want.
Then select the save option and then the go button.

You would do the same for the date but like I said I don't know what format it is in.


Blue Man Group
There is no such thing as stupid questions. Just stupid answers
Joined: Apr 2007
Posts: 3,940
Likes: 1
SD Offline
Former Developer
Former Developer
Joined: Apr 2007
Posts: 3,940
Likes: 1
go to your Admin Control Panel, Database Tools, SQL Command

SQL Query
UPDATE ubbt_CACHE SET max_online=0;

paste that into the textarea and execute it.. that will reset you to 0 and a recalculation will ensue wink

note: this assumes your table prefix is 'ubbt_' -- change it as appropriate for your forums wink

Joined: Jan 2009
Posts: 22
W
stranger
stranger
W Offline
Joined: Jan 2009
Posts: 22
Thank you SirDude.

In the same way, how do I change the date to say, 30th November 2008?

Much appreciated.

Joined: Apr 2007
Posts: 3,940
Likes: 1
SD Offline
Former Developer
Former Developer
Joined: Apr 2007
Posts: 3,940
Likes: 1
well, since you set it to 0, it's going to compute to a new date at a point when you have at least ONE person online..

are you saying you want to fix the date to a specific value? if so, why ?

don't you want it to be a true value that counts up from here on out?

:shrug:

but if you really want to force the issue, go to your Admin Control Panel, Database Tools, SQL Command

SQL Query
UPDATE ubbt_CACHE SET max_onlinetimestamp=1228003200;

paste that into the textarea and execute it.. that will set the date to 11/30/2008 (unixtime) and a recalculation will ensue wink

Joined: Jan 2009
Posts: 22
W
stranger
stranger
W Offline
Joined: Jan 2009
Posts: 22
Thanks

With the above line I got this

Line#: 101
SQL Error: Unknown column 'max_onlinetimestamp' in 'field list'
SQL Error #: 1054
Query: UPDATE ubbt_CACHE SET max_onlinetimestamp=1228003200;


frown

Joined: Dec 2003
Posts: 6,566
Likes: 78
Joined: Dec 2003
Posts: 6,566
Likes: 78
the field name is
max_online_timestamp
not
max_onlinetimestamp


Blue Man Group
There is no such thing as stupid questions. Just stupid answers
Joined: Jan 2009
Posts: 22
W
stranger
stranger
W Offline
Joined: Jan 2009
Posts: 22
Thanks. Unfortunately I got the same

Line#: 101
SQL Error: Unknown column 'max_online_timestamp' in 'field list'
SQL Error #: 1054
Query: UPDATE ubbt_CACHE SET max_online_timestamp=1228003200;

Any ideas?
thanks

Joined: Apr 2007
Posts: 3,940
Likes: 1
SD Offline
Former Developer
Former Developer
Joined: Apr 2007
Posts: 3,940
Likes: 1
what version of threads you using? max_online_timestamp is what i have for it..

Joined: Jan 2009
Posts: 22
W
stranger
stranger
W Offline
Joined: Jan 2009
Posts: 22
I just looked it is 7.3

Thanks

Joined: Jan 2009
Posts: 22
W
stranger
stranger
W Offline
Joined: Jan 2009
Posts: 22
Anyone any idea? frown

Thanks

Joined: Dec 2003
Posts: 6,566
Likes: 78
Joined: Dec 2003
Posts: 6,566
Likes: 78
If you still have not resolved this try opening the table as I suggested and set it manually Like I stated before.
Not knowing that version you have maybe it has a slightly different name.


Blue Man Group
There is no such thing as stupid questions. Just stupid answers
Joined: Apr 2007
Posts: 3,940
Likes: 1
SD Offline
Former Developer
Former Developer
Joined: Apr 2007
Posts: 3,940
Likes: 1
and i STILL don't know why setting a specific date is even desired..

if you set it to ZERO (the amount), then both fields will be recalculated as soon as ONE person logs in.. that will be the NEW high..

:shrug:

Joined: Jun 2006
Posts: 16,301
Likes: 116
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,301
Likes: 116
Originally Posted by Sirdude
and i STILL don't know why setting a specific date is even desired..
agree, why skew actual stats?


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum, Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Joined: Jan 2009
Posts: 22
W
stranger
stranger
W Offline
Joined: Jan 2009
Posts: 22
OK then I tried

UPDATE ubbt_CACHE SET max_online=0;

and I get this message:

Script: ..../dodbcommand.php
Line#: 101
SQL Error: Unknown column 'max_online' in 'field list'
SQL Error #: 1054
Query: UPDATE ubbt_CACHE SET max_online=0;



Thanks

Joined: Jun 2006
Posts: 9,242
Likes: 1
R
Former Developer
Former Developer
R Offline
Joined: Jun 2006
Posts: 9,242
Likes: 1
It's not actually a field name, rather a value:

SQL Query
update ubbt_CACHE
set CACHE_VALUE = '0'
where CACHE_FIELD = 'max_online'

Joined: Apr 2007
Posts: 3,940
Likes: 1
SD Offline
Former Developer
Former Developer
Joined: Apr 2007
Posts: 3,940
Likes: 1
ah yes, of course... tongue

/me hangs head in shame for SQL syntax gag.... :sniff:


Link Copied to Clipboard
ShoutChat
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Recent Topics
Version 7.7.5 Images suddenly not displaying
by Stovebolt - 05/04/2024 11:19 AM
Bots
by Outdoorking - 04/13/2024 5:08 PM
Can you add html to language files?
by Baldeagle - 04/07/2024 2:41 PM
Do I need to rebuild my database?
by Baldeagle - 04/07/2024 2:58 AM
This is not a bug, but a suggestion
by Baldeagle - 04/05/2024 11:25 PM
Who's Online Now
1 members (Ruben), 667 guests, and 166 robots.
Key: Admin, Global Mod, Mod
Random Gallery Image
Latest Gallery Images
Los Angeles
Los Angeles
by isaac, August 6
3D Creations
3D Creations
by JAISP, December 30
Artistic structures
Artistic structures
by isaac, August 29
Stones
Stones
by isaac, August 19
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Preview build 20240506)