1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Sharing information across PHP sessions ?

Discussion in 'PHP' started by ammar26, Apr 25, 2011.

  1. #1
    Im am trying to share the data between 2 different users (logged from their own machines) to a server.
    Can i share the sessions of PHP of both users ?

    I'm trying to implement that if some user types the string from his keyboard it must appear in other user window
    how i can share that info ? i mean can i share sessions of 2 different users ?
    SEMrush
    The only solution rite now i know is using the mySQL at back end, but is there is any method that can help me out, i mean global variables on PHP server that can be shared among all users ? or session sharing
     
    ammar26, Apr 25, 2011 IP
    SEMrush
  2. ap2010

    ap2010 Guest

    Messages:
    41
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    0
    #2
    You'll definitely need mysql or some other centralized mechanism to share message between two logged in users. You can search for open source chat systems to see how they work.

    Having said that, you can use plain text files for this purpose (if your needs are simple). Just write down the information to be shared in a text file and scan (and display) its content on each page.
     
    ap2010, Apr 25, 2011 IP