Jump to content


tracking the visitors which visited a profile.


2 replies to this topic

#1 sami

    Young Padawan

  • Members
  • Pip
  • 1 posts

Posted 02 October 2006 - 02:52 AM

there'r registered users they have profile. how i can get the registers users who visited the other registered user profile. for example, if there'r a,b,c, members, and b and c visits the the profile of member a.. how i can show that ?

#2 InFnit

    P2L Jedi

  • Members
  • PipPipPip
  • 822 posts
  • Interests:My interests are my:<br><br>iidsite - http://iid.outer-heaven.net<br>iidblog - http://iid.outer-heaven.net/blog/<br>iidcommunity - http://iid.outer-heaven.net/forums/<br>P2L - http://www.pixel2life.com

Posted 02 October 2006 - 05:48 AM

Collect the UserID from the logged in cookie, then each time someone accesses someones profile check to see if their ID is already in the Visited list (ie "b,c") if it's not add a ",d" at the end of it.

To check you just explode() the string into an array. Then to add you implode() it back into a string before updating the field in mySQL.

That's how I would do it.

#3 NGPixel

    Senior Programmer

  • P2L Staff
  • PipPipPipPip
  • 1,410 posts
  • Gender:Male
  • Location:Montreal, Canada
  • Interests:Web Design : Coding : Animation

Posted 02 October 2006 - 12:14 PM

no need to break down the array, you can check using the in_array() function, and add another key at the end using array_push() function.





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users