I want to be able to identifying users to my website so that I can see when they last logged on and highlight changes to certain pages when they see them for the first time. One problem is that a user's IP address may be dynamic, so I don't see that I can rely on the IP address. Can anyone suggest a way to do this?

Dave.

Recommended Answers

All 6 Replies

have a last login in the database and then if its blank for that user, highlight otherwise don't.

if you have different areas on different pages, you might need to create a table for the pages and have the unique identifier the members id and then put a 0 or 1 if they have visited that page.

My users don't login, it's merely an information type website, so I cannot identify them that way.

If you do not have users logging in you could use cookies to store the time/date they last accessed the site for this.

sorry about that, i saw "logged on" and figured you had a login on the site. now i understand why you were talking about an ip address.

cookies, like xan mentioned, would do it, but they are not that reliable either. i clear my cookies everyday, so this would do much for people like me. Compared to anything else i have used/can think of cookies would be the best way.

Tanks Xan and kkeith29, i guess cookies is the best option, but there is no perfect answer.

if u want to check out when your site got visited 4 last time {without mentioning the user} u can set a session in your index page and insert the date and time to a table(if session 4 a particular variable is not set.)
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.