Thread: [Phplib-users] Max's session class
Brought to you by:
nhruby,
richardarcher
|
From: Matt W. <li...@ye...> - 2002-03-12 18:43:23
|
Hi I've been playing with max's session class with plplib 7.2c for a long time with much success. I thought I'd download 7.4pre1 and see how far along things have come with integrating php 4 sessions with phplib. First of all fired it up with default php sessions, worked fine. Altered the settings to work with the max's session 4 stuff. No go I then noticed that max's session4_custom was calling session/session4.inc Got this from cvs and all is well. Shouldn't this be included in the unsup folder of the distro? Also which direction is phplib with php4 session being taken in? I know the cvs was a mess before we moved but it now seems like an organised mess. Which session4 stuff are we supposed to be working on? Is max's class been incorporated into the sesion4 folder or is that still the other session4 stuff? I'm not trying to diss anyone but I would like to know which session 4 files I should be working with to get us towards the full integration. matt |
|
From: Matt W. <ma...@ye...> - 2002-03-12 20:55:25
|
On Tuesday 12 March 2002 20:24, Richard Archer wrote: > Nathan rushed some PHP4 stuff into the pre1 release. If that's not > the best code to be using, we'd best hear about it before it becomes > the standard! That's Max's stuff, however, the session4_custom.inc requires session4 which is in the phplib4 folder. Maybe these should be merged together? > My understanding was that Max's code was the "best", although I > didn't pay much attention to PHP4 discussions last year (still > using PHP3!). > > Which code do you think we should be using? > And which code is in pre1? As I said above it's Max's that's in the distro. This is the one I would go for, only because it's the only one I got working. I've been using it on a couple of sites for the past 12 months or more and have had no problems with it. I've been using it with 7.2c with php 4.0.6. I don't however use the user stuff. I've just set up a test site here using 7.4 to see how it works with the new lib stuff. I'm also trying to get it running with register_globals off but I'm begging to think just to try and see how the session stuff reacts first. matt |
|
From: Maxim D. <max...@bo...> - 2002-03-13 08:22:09
|
Hello Matt, Tuesday, March 12, 2002, 11:53:34 PM, you wrote: MW> That's Max's stuff, however, the session4_custom.inc requires session4 which MW> is in the phplib4 folder. MW> Maybe these should be merged together? That's not true. Session4_custom does not require any of the phplib4 stuff. The session4 class you need is in the session4.inc in php/session - Ulf & me divided the original session4_custom class in two to abstract the common session routines and make the custom handler really 'custom'. Now you can only use session4.inc if you don't want custom storage, but only standard savehandlers. And you can plug in session4_custom to have Mysql, etc. storage using CT_* classes. -- Best regards, Maxim Derkachev mailto:max...@bo... System administrator & programmer, Symbol-Plus Publishing Ltd. phone: +7 (812) 324-53-53 www.books.ru, www.symbol.ru |
|
From: Giancarlo P. <gia...@na...> - 2002-03-12 22:41:56
|
Matt Williams wrote: > > Hi > > I've been playing with max's session class with plplib 7.2c for a long time > with much success. > > I thought I'd download 7.4pre1 and see how far along things have come with > integrating php 4 sessions with phplib. > > First of all fired it up with default php sessions, worked fine. > Altered the settings to work with the max's session 4 stuff. No go > It looked somthing strange to me, those subdirectories etc. and i needed to convert an existing session3 site. So I just followed the other suggestion: how to wedge the 4 stuf into a 3 implementation: copy all the unsup dir, prepend.php4 there is OK to be substituted to your one, and it worked quite out of the way... Gian |
|
From: Alexander M. <am...@si...> - 2002-03-17 12:10:21
|
Hi... i am looking for a phplib session class which uses php4 sessions stored in the active_sessions table in the database. I found the session4_custom in the cvs but i can't get it running. Does someone have an running class for me ? Greetings Alex |
|
From: Tarique S. <ta...@sa...> - 2002-03-17 12:31:31
|
On Sun, 17 Mar 2002, Alexander Meis wrote: Hello Have you taken a look at http://www.sanisoft.com/phplib/manual/php4_sessions.php HTH Tarique > Hi... > > i am looking for a phplib session class which uses php4 sessions stored in > the > active_sessions table in the database. > I found the session4_custom in the cvs but i can't get it running. > Does someone have an running class for me ? > > Greetings > > Alex > > > _______________________________________________ > Phplib-users mailing list > Php...@li... > https://lists.sourceforge.net/lists/listinfo/phplib-users > -- ============================================================= PHP Applications for E-Biz: http://www.sanisoft.com Indian PHP User Group: http://groups.yahoo.com/group/in-phpug ============================================================= |
|
From: Matt W. <li...@ye...> - 2002-03-13 08:48:34
|
On Wednesday 13 March 2002 08:25, Maxim Derkachev wrote: > That's not true. Session4_custom does not require any of the phplib4 > stuff. The session4 class you need is in the session4.inc in > php/session - Ulf & me divided the original session4_custom class in > two to abstract the common session routines and make the custom handler > really 'custom'. Now you can only use session4.inc if you don't want > custom storage, but only standard savehandlers. And you can plug in > session4_custom to have Mysql, etc. storage using CT_* classes. So we have two session4's in the CVS or are they both the same? Because the session4.inc in phplib-4 works with your class Max. I've never looked at the stuff in phplib-4 because I got Max's one working pretty good. If it is the stuff from the CVS session folder, session4.inc should be included in the distro, yes? This goes back to the questions that keep getting getting asked. Which session4 stuff whould we be working on/with. The stuff in phplib-4 or the stuff in session? Seems like we've got people channeling time and effort into two different version of more or less the same thing. matt |
|
From: Maxim D. <max...@bo...> - 2002-03-13 09:16:50
|
Hello Matt, Wednesday, March 13, 2002, 11:46:28 AM, you wrote: MW> So we have two session4's in the CVS or are they both the same? Because the MW> session4.inc in phplib-4 works with your class Max. MW> I've never looked at the stuff in phplib-4 because I got Max's one working MW> pretty good. Well, that could be - they export the same public API. But if You look close to the session4 in the phplib4 folder, You will see that the file consists of many lines from session3 class commented out, with some plugs for php4 session support. It uses the old-fashion serialize (instead of PHP4 serialize, which is much much better). It does not make use of session setup functions from the php4 module for setting up cache control, cookies behaviour, etc. Just compare the session4 classes in session/ & phplib4/ to see the changes. The session4.inc in the session folder was designed with maximum php4 session module usage in mind and session3 public API compatibility (we could not save all the things that are present in the session3, like $sess->in & $sess->pt, but it is only because it could not be achieved without messing the things up). MW> If it is the stuff from the CVS session folder, session4.inc should be MW> included in the distro, yes? Yes. The only file that was intended to be used with the session4_custom, is session4.inc from the session folder. -- Best regards, Maxim Derkachev mailto:max...@bo... System administrator & programmer, Symbol-Plus Publishing Ltd. phone: +7 (812) 324-53-53 www.books.ru, www.symbol.ru |
|
From: Donncha O C. <don...@tr...> - 2002-06-27 11:02:46
|
Hi all, I'm dragging up an old thread but I'm only now getting around to investig= ating=20 PHP4 properly. I'm trying to figure out which session class to use with P= HP4. The stable directory has the following: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/phplib/php-lib-stable/unsu= p/ which were added only 5 months ago And the unstable has=20 http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/phplib/php-lib/php/session= /=20 which are older files. The session4_custom.inc in each directory is exactly the same, but the st= able=20 directory doesn't have a session4.inc file which confused me as it's requ= ired=20 by the former file. Shouldn't session4.inc be in the tarball that's relea= sed=20 to the public? (this question was also raised elsewhere in this thread la= st=20 March..) To install the session code, I think I do the following.. 1. Download the session4.inc file from=20 http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/phplib/php-lib/php/session= /session4.inc 2. Copy that file to my include directory in a sub-directory called sessi= on. 3. Rename session.inc in my include directory so it's out of the way. 4. Copy ~/phplib-7.4-pre1/unsup/session4_custom.inc to session.inc in my=20 include directory. 5. Change local.inc so that the session class there inherits from=20 Custom_session and configure the storage variables and other settings. Is that correct? If it is, it's going on a webpage so Google can find it,= the=20 list archives don't seem to there.. Donncha. On Wednesday 13 March 2002 09:20, Maxim Derkachev wrote: > Hello Matt, > > Wednesday, March 13, 2002, 11:46:28 AM, you wrote: > > MW> So we have two session4's in the CVS or are they both the same? Bec= ause > the MW> session4.inc in phplib-4 works with your class Max. > > MW> I've never looked at the stuff in phplib-4 because I got Max's one > working MW> pretty good. > > Well, that could be - they export the same public API. But if You look > close to the session4 in the phplib4 folder, You will see that the > file consists of many lines from session3 class commented out, with > some plugs for php4 session support. It uses the old-fashion serialize > (instead of PHP4 serialize, which is much much better). It does not > make use of session setup functions from the php4 module for setting up > cache control, cookies behaviour, etc. > Just compare the session4 classes in session/ & phplib4/ to see the > changes. The session4.inc in the session folder was designed with maxim= um > php4 session module usage in mind and session3 public API compatibility= (we > could not save all the things that are present in the session3, like > $sess->in & $sess->pt, but it is only because it could not be achieved > without messing the things up). > > MW> If it is the stuff from the CVS session folder, session4.inc should= be > MW> included in the distro, yes? > > Yes. The only file that was intended to be used with the > session4_custom, is session4.inc from the session folder. |
|
From: Mike G. <Mik...@sa...> - 2002-03-13 22:08:27
|
Could someone give some pros and cons of using session4.inc vs session4_custom, i.e., (apparently of) using a standard PHP4 save_handler vs MySQL, etc., storage using CT_* classes? And for that matter, pros and cons of using a save_handler vs those supplied by PHP4 sessions? TIA! Mike Green Maxim Derkachev wrote: > Hello Matt, > > Wednesday, March 13, 2002, 11:46:28 AM, you wrote: > > MW> So we have two session4's in the CVS or are they both the same? Because the > MW> session4.inc in phplib-4 works with your class Max. > > MW> I've never looked at the stuff in phplib-4 because I got Max's one working > MW> pretty good. > > Well, that could be - they export the same public API. But if You look > close to the session4 in the phplib4 folder, You will see that the > file consists of many lines from session3 class commented out, with > some plugs for php4 session support. It uses the old-fashion serialize > (instead of PHP4 serialize, which is much much better). It does not > make use of session setup functions from the php4 module for setting up cache > control, cookies behaviour, etc. > Just compare the session4 classes in session/ & phplib4/ to see the > changes. The session4.inc in the session folder was designed with maximum php4 > session module usage in mind and session3 public API compatibility (we could > not save all the things that are present in the session3, like $sess->in & $sess->pt, > but it is only because it could not be achieved without messing the things up). > > MW> If it is the stuff from the CVS session folder, session4.inc should be > MW> included in the distro, yes? > > Yes. The only file that was intended to be used with the > session4_custom, is session4.inc from the session folder. > > -- > Best regards, > Maxim Derkachev mailto:max...@bo... > System administrator & programmer, > Symbol-Plus Publishing Ltd. > phone: +7 (812) 324-53-53 > www.books.ru, www.symbol.ru > > _______________________________________________ > Phplib-users mailing list > Php...@li... > https://lists.sourceforge.net/lists/listinfo/phplib-users -- Mike Green SaeSolved:: http://www.saesolved.com http://www.everypeople.net http://www.sitewidgets.com http://www.widgetchuck.com |
|
From: Tarique S. <ta...@sa...> - 2002-03-15 06:11:39
|
On Wed, 13 Mar 2002, Mike Green wrote: > Could someone give some pros and cons of using session4.inc vs > session4_custom, i.e., (apparently of) using a standard PHP4 > save_handler vs MySQL, etc., storage using CT_* classes? And for that > matter, pros and cons of using a save_handler vs those supplied by > PHP4 sessions? One thing that we need sessions data in table is to allow admin to hijack sessions and change data for other users even as they work - This has its uses ;-) Tarique -- ============================================================= PHP Applications for E-Biz: http://www.sanisoft.com Indian PHP User Group: http://groups.yahoo.com/group/in-phpug ============================================================= |
|
From: Donncha O C. <don...@tr...> - 2002-06-27 14:19:41
|
Documented all that at=20 http://xeer.blogspot.com/?/2002_06_01_xeer_archive.html#78265256 Feel free to comment or correct what I've written there. Donncha. On Thursday 27 June 2002 12:02, Donncha O Caoimh wrote: > Hi all, > > I'm dragging up an old thread but I'm only now getting around to > investigating PHP4 properly. I'm trying to figure out which session cla= ss > to use with PHP4. > > The stable directory has the following: [snip] |
|
From: nathan r. h. <na...@ds...> - 2002-06-27 19:16:56
|
God that's a friggin ugly workflow :) Will be fixed soon, I hope. -n ------ nathan hruby na...@ds... ------ On Thu, 27 Jun 2002, Donncha O Caoimh wrote: > Documented all that at > http://xeer.blogspot.com/?/2002_06_01_xeer_archive.html#78265256 > > Feel free to comment or correct what I've written there. > > Donncha. > > > On Thursday 27 June 2002 12:02, Donncha O Caoimh wrote: > > Hi all, > > > > I'm dragging up an old thread but I'm only now getting around to > > investigating PHP4 properly. I'm trying to figure out which session class > > to use with PHP4. > > > > The stable directory has the following: > [snip] > > > ------------------------------------------------------- > Sponsored by: > ThinkGeek at http://www.ThinkGeek.com/ > _______________________________________________ > Phplib-users mailing list > Php...@li... > https://lists.sourceforge.net/lists/listinfo/phplib-users > |
|
From: Peter K. <su...@si...> - 2002-06-28 09:43:37
|
> > God that's a friggin ugly workflow :) Will be fixed soon, I hope. > yes - really ;-) but ... thank you, Donncha, for rewinding the old thread - I am so happy with the session4 stuff, it seems to work and it is so much faster than with the MySQL database!!! Thank you all! Peter Kursawe. |
|
From: Maxim D. <max...@bo...> - 2002-06-27 14:37:45
|
Hello Donncha, Thursday, June 27, 2002, 6:19:41 PM, you wrote: DOC> Documented all that at DOC> http://xeer.blogspot.com/?/2002_06_01_xeer_archive.html#78265256 That's wrong. session4_custom.inc should be downloaded from http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/phplib/php-lib/php/session/session4_custom.inc , not from the unsup directory. -- Best regards, Maxim Derkachev mailto:max...@bo... IT manager, Symbol-Plus Publishing Ltd. phone: +7 (812) 324-53-53 www.books.ru, www.symbol.ru |
|
From: Maxim D. <max...@bo...> - 2002-06-27 14:40:41
|
oops ... forgot that 'custom' is in the pre-release now ... :) Seems right then. DOC>> Documented all that at DOC>> http://xeer.blogspot.com/?/2002_06_01_xeer_archive.html#78265256 MD> That's wrong. session4_custom.inc should be downloaded from MD> http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/phplib/php-lib/php/session/session4_custom.inc , MD> not from the unsup directory. -- Best regards, Maxim Derkachev mailto:max...@bo... IT manager, Symbol-Plus Publishing Ltd. phone: +7 (812) 324-53-53 www.books.ru, www.symbol.ru |
|
From: Donncha O C. <don...@tr...> - 2002-06-27 14:44:38
|
Glad to hear it, it's much faster with PHP4! Thanks for all the hard work= ! Donncha. On Thursday 27 June 2002 15:40, Maxim Derkachev wrote: > oops ... forgot that 'custom' is in the pre-release now ... :) > Seems right then. > > DOC>> Documented all that at > DOC>> http://xeer.blogspot.com/?/2002_06_01_xeer_archive.html#78265256 > > MD> That's wrong. session4_custom.inc should be downloaded from > MD> > http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/phplib/php-lib/php/sessi= on/s >ession4_custom.inc , MD> not from the unsup directory. |