Sessioning should be fixed now, I think. February 22, 2001 1:05 AM   Subscribe

I think I fixed the sessioning. I reworked a lot of code tonight, and tested it, and I think I got it working correctly. Here's what's going on: you come to metafilter for the first time today, it says 3 new links and 24 new comments. You read the site, hitting the index page as many times as you want, and you'll never lose that 3 links and 24 comments status.

then you go away for a few hours, and you come back. it should say "1 new link and 13 new comments" (if that much changed between visits), and it should remain that way until you go away for over 15 minutes.

Now, the only place where this will be screwed up, is when you hit the site within 15 minutes from your last visit. That way, the session won't die and it won't update your last visit time.

I also got rid of the new window thing, and the double arrow things, since you won't lose state if you jump directly into a thread.

Let me know if you find any problems.
posted by mathowie (staff) to MetaFilter-Related at 1:05 AM (26 comments total)

I really liked not having to manually open a new window (my preference for reading MeFi anyway). Could this maybe be a preference ("Open threads... in new window") to go with the existing one to make links open in their own window?
posted by kindall at 2:46 AM on February 22, 2001

Oh yeah. Forgot to mention that the sessioning works fine fo rme!
posted by kindall at 2:46 AM on February 22, 2001

Sounds great Matt, I hope it works.

I always felt like a little part of me died whenever I accidentally reloaded the index page and lost my new links/comments info.
posted by sudama at 6:46 AM on February 22, 2001

I discovered the sectioning by accident this morning. I clicked on the "new" link (not catching the missing double-arrow thingy) then closed the window and realized I'd closed my main metafilter window.

It took me three times of doing that before I realized the "new" link wasn't opening a new window. :-) That's what I get for surfing in the morning.

Anywho, I thought I was going to lose the indicators of the 100 some-odd new messages, and I didn't! And I was happy! Three times in 5 minutes.. "D'oh!" "Woohoo!" "D'oh!" "Woohoo!" "D'oh!" "Woohoo!"

I need to drink more coffee before getting online. :-) It works great Matt, thanks, but add my voice to kindall's, requesting a user option for the new posts in a new window thing.
posted by cCranium at 7:10 AM on February 22, 2001

User option for new posts in a new window: hold shift while clicking (in IE on Windows)....and there are modifier keys for other browsers as well.
posted by jkottke at 8:50 AM on February 22, 2001

Next up: the pony!
posted by rodii at 8:53 AM on February 22, 2001

Jason: Suggestion. Matt asks for commentary on his changes, we provide commentary.

Just because I'm a functional idiot doesn't mean I'm stupid. :-)

Also, the "new" link actually jumping to the first new post anchor seems to randomly be failing. The url gets the anchor passed with it, but the page isn't jumping. It's quite possibly client-side.
posted by cCranium at 11:35 AM on February 22, 2001

The url gets the anchor passed with it, but the page isn't jumping

Really? I've never seen this happen, you sure you're not clicking on a link that has as many new messages as there are comments (in which case, it wouldn't jump very far at all), or that when you jump to a thread with 2 or 3 comments, it's often not enough to scroll. Make your window really short, and it should work no matter what. Maybe that's the effect you're seeing?
posted by mathowie (staff) at 12:56 PM on February 22, 2001

Yes, and I was responding to your suggestions with an alternate solution.

Matt, I have seen that error on my browser as well (IE 5 on Win2K) happens about once every 10 times when I follow permalinks on weblogs (including my own). The page loads, but it doesn't jump to the proper anchor in the page. Hasn't happened to me on MeFi yet though. And I apologize for not defining any words in this paragraph...I hope it doesn't interfere with your understanding of it.
posted by jkottke at 1:13 PM on February 22, 2001

oh, it's IE! damn microsoft!
posted by mathowie (staff) at 1:15 PM on February 22, 2001

Actually, now that I think about it, sometimes anchors don't work in IE (especially with blogs and blog posts) and I noticed that sometimes you have to hit return in the URL bar to resubmit the page and get it to jump down.
posted by mathowie (staff) at 1:31 PM on February 22, 2001

"I always felt like a little part of me died whenever I accidentally reloaded the index page..."

How marvelously overstated! I like this quote. I also like Jason's stubbornly overdone definition hyperlinking. Overall, this is one stellar MetaTalk thread. I'd recommend it to friends.

And yes, IE 5.5's anchor jumping is dorked. Don't know about 5.x tho...
posted by anildash at 1:51 PM on February 22, 2001

Shouldn't your comment be in metatalk anil? Take it outside buddy...
posted by mathowie (staff) at 4:38 PM on February 22, 2001

Er...Matt? [looks around] These comments are in MetaTalk. Or did you mean take it into the Big Room?
posted by bradlands at 7:56 PM on February 22, 2001

A little more info. I am using 5.5, so that's probably it. When it doesn't jump, refreshing the page and/or pressing enter from inside the address bar also doesn't jump to the anchor.

I should've checked the code, see if the anchor got loaded, but I thought of it too late.

I bow to Jason's mastery of the sarcastic smack-down, and apologize for being in a snit yesterday when I started it.
posted by cCranium at 5:34 AM on February 23, 2001

Who the hell leaves MeFi for a full 15 minutes??? I mean, I occasionally leave for five or ten, but other than lunch and my commute home - NEVER 15! What about me and my compulsive clicking needs???

Jason: Good Suggestion.
Matt: Would you come over and hold my shift key for me?
posted by CrazyUncleJoe at 11:24 AM on February 23, 2001

What anil said. ROFL. Me too sudama.

The anchor thing has been driving me crazy. People link to specific blogger posts and then you don't find it and you have to hover over the permalink in order to figure out which one they meant. (Heck, people have started linking to specific posts here ...)
posted by dhartung at 2:17 PM on February 23, 2001

Thank you CrazyUncleJoe. Now I don't feel alone.
posted by john at 4:05 PM on February 23, 2001

First Jason picks on Cranium, then Matt's mean to me. Man, I hate a-listers. mean bastards.
posted by anildash at 7:55 PM on February 23, 2001

anil, a quote from Snatch:

"Do you know what 'nemesis' means? A righteous infliction of retribution manifested by an appropriate agent. Personified in this instance by an 'orrible cunt... me!"
posted by mathowie (staff) at 9:31 PM on February 23, 2001

Wait, does that mean that, using a fair amount of extrapolation, inference and wildly crazy conspiracy fantasies that Jason's my nemesis?

Woah. I should like, build an underground laboratory from which to take over the world.

(Jason's the good guy, right? Or do I have to infilatrate his secret satellite? I'm so confused!)
posted by cCranium at 7:26 AM on February 26, 2001

Is it relevant if I mention that I have a special group on my buddy list called "Nemeses"?
posted by anildash at 12:05 PM on February 26, 2001

Possibly. You aren't allied with Jason, are you? From the sounds of things, that would mean I'd have to install AIM so you could add me to your poorly named buddy list.

And doing that would _definitely_ make me your nemesis. :-)
posted by cCranium at 12:25 PM on February 26, 2001

("buddy" being the poorly named part, that is. I actually like the idea of a "nemeses" section, it beats out my "geeks", "time leeches", and "other" namings. :-)
posted by cCranium at 12:26 PM on February 26, 2001

I don't know if this is technically feasible, but would it be possible to reset the message count for a particular thread to 0 when that thread is read? That would let us quickly determine which threads have new messages since the last time we read them, even if that was only ten minutes ago, and it would do away with the session idea as well. I guess it would probably require keeping a message pointer for each thread, per user, which might be a bit of a space hog... your current method probably doesn't require that.

A big 'ol "mark all read" button on the front page that caught up our session-start time to the current time would be a good second choice...
posted by kindall at 11:35 PM on March 7, 2001

Or, and similar, a way to set our session infomation to a specific date/time.
posted by cCranium at 5:54 AM on March 8, 2001

« Older weirdness   |   Spellcheck Function Not Functioning Newer »

You are not logged in, either login or create an account to post comments