Forums

PHP

This topic is locked

Why does session_register not work on Windows?

Posted 04 May 2007 23:57:32
1
has voted
04 May 2007 23:57:32 Kenneth Halley posted:
Can anyone explain to me why the session_register function never seems to work in windows . As an example the default login user script in DW if i add that to a page (untouched)- usually I end up hacking it round to suit my purposes- but I digress!,It uses the session register function to initiate the sessions. I use this on the hosting server no problem at all but if I use it on a locally run server (by that I mean my development machine or one of my test servers running windows with apache/mysql on) I can never get logged ontot he test site and the reason is session register. the session exists withthe key but the value is always blank. tried this on three different machines and always the same.

As a work round I use $_SESSION['value']=$somevalue;

which seems OK (not sure if there is anything fundamentally wrong in this approach).

For info I use the devside.net developer suite to build my webserver/database server from- a lot easier than trying to configure everything individually. The only thought I had was it was something in php.ini but can't see a parameter I can blame for this issue.

Anyone know why this is? No big deal by the way- not sitting waiting for an immediate answer just one of those- have you ever wondered why? type questions!
cheers
Kenny

-----------------------------------
www.halleynet.co.uk

Replies

Replied 09 May 2007 04:09:32
09 May 2007 04:09:32 Alan C replied:
I have an idea that the session register function is depracated and that the approach you are taking is now the recommended one, unfortunatley I can't recall where I saw that
Replied 14 May 2007 00:59:00
14 May 2007 00:59:00 Kenneth Halley replied:
The approach I am now using is the one in the php manual- so maybe your right. Actually I find th elogin script a bit of a pest in DW, as you invariably nee dot hack it to add things link MD5 encryption and stuff. You would think they would have options for this as default? Well I would anyway.
Thanks for the answer- at least it makes me feel I am not doing anything drastically wrong! <img src=../images/dmxzone/forum/icon_smile.gif border=0 align=middle>

-----------------------------------
www.halleynet.co.uk

Reply to this topic