1

Topic: A minor bug

Or maybe it has been done on purpose but I use 2 computers the one in school and the on at home .. If I post something from one computer if I check on the other computer logged in with the same account it says that it's a new post even that I posted it myself.

S C U B A

Re: A minor bug

Well, it's not "on purpose", but PunBB stores the last visit information in a cookie and because of that, you can have different last visit times if you visit the same board from different computers.

I'm looking into this for 1.1. Moving the info to the database would involve running one more query (an update of the users table) in all pages, so I'm a bit reluctant.

"Programming is like sex: one mistake and you have to support it for the rest of your life."

Re: A minor bug

A low priority insert perhaps?
as it usually takes a while going from home to work and vice versa...

Dunno how long it can be delayed in a frequently visited forum though...

Re: A minor bug

How do you mean? What should I insert?

"Programming is like sex: one mistake and you have to support it for the rest of your life."

Re: A minor bug

I think Frank means you could do a low-prio insert on the lastvisit in that extra query.

I'm not sure that there is such an option för pgsql tho.

One possible solution is to have a userconfigurable option in profile 'Always store last visit' and leave it off by default, with some descriptive text on that it's usefull for ppl using more then one pc to visit punbb forums?

Re: A minor bug

Yeah, I got that part, but what should I insert? One solution is to have a field "last_visit" in the users-table and then update it now and then. That would involve an update, not an insert.

"Programming is like sex: one mistake and you have to support it for the rest of your life."

7 (edited by Frank H 2003-10-02 15:00)

Re: A minor bug

true ... it should be a update ... but there is an update low priority in mysql as well ...
http://www.mysql.com/doc/en/UPDATE.html

unfortunately postgre doesn't have this feature of delayed inserts...


Is there perhaps a query for cookies or similar you could include this in, so that it will more or less not be noticable with another query?

Re: A minor bug

Ah yes, I could (and probably would) do a LOW_PRIORITY query. It is however still another query and I can't think of another query that I can somehow include it in. Oh well, we'll see :)

"Programming is like sex: one mistake and you have to support it for the rest of your life."

Re: A minor bug

I fixed it by storing last_visit in the database and last_action in the cookie. So, for every page view, last_action is updated, but it's only when the user times out that the database is updated.

"Programming is like sex: one mistake and you have to support it for the rest of your life."

Re: A minor bug

nice smile