ori wrote: was that in login cos i did a lava edit and had 2 put $_SESSION['sid']=md5($did);
Yes ori. I face that problem from login.php. I am using lavalair wml version.
Wait...
Started on the old forum in January 2009 · view the original in the archive · old links redirect here
Written automatically from the replies by a language model on our own server. It can be wrong; the posts below are the source.
ori wrote: was that in login cos i did a lava edit and had 2 put $_SESSION['sid']=md5($did);
Yes ori. I face that problem from login.php. I am using lavalair wml version.
Wait...
I am 50% successful. It is working except WAP 1.0 browser. This kind of browsers cant collect session. So when users with this browsers try to enter homepage it shows "session expired", at the same time if anyone uses WAP 2.0 browser he can enter homepage successfully.
Whats the solution for it?
Wait...
Hide Session ID in lava/wapd
This is what i've done successfully.. In core.php put this
session_start(); $sid = $_SESSION['sid'];
on top or bottom then in login.php find
$sid = md5($did);
and change it to
$_SESSION['sid'] = md5($did); $sid = $_SESSION['sid'];
observe it..After defining $_SESSION['sid'] as an md5($did) then define $sid as $_SESSION['sid'] so that it means $sid = $_SESSION['sid'] while the value of $_SESSION['sid'] = md5($sid); then on every page, you don't need to put something 'cause the session_start() and $sid = $_SESSION['sid'] is already in core.php and core.php is already included on every page..You just need to remove all $sid = $_GET['sid'] and all &sid=$sid..To display if not logged in or session expired i made this code
if(($action != "") && ($action!="terms") && ($action!="gviewfrm") && ($action!="gviewcat") && ($action!="gviewtpc") && ($action!="gforumindx"))
{
$uid = getuid_sid($sid);
if((empty($_SESSION['sid']) OR (!isset($_SESSION['sid'])))
{
put here your codes for ses expire
}
}
then to destroy session, put this on top or bottom of the msg successfully logged out,
unset($_SESSION['sid']); $_SESSION = array(); session_destroy();
My Blog: http://jhommark.blogspot.com My Facebook: http://www.facebook.com/jhommark My Official Site: http://www.undergroundweb.tk My Community Site: http://undergroundwap.xtreemhost.com
i allready try this code and i work good ahehhehe
if(($action != "") && ($action!="terms") && ($action!="gviewfrm") && ($action!="gviewcat") && ($action!="gviewtpc") && ($action!="gforumindx"))
{
$uid = getuid_sid($sid);
if((empty($_SESSION['sid']) OR (!isset($_SESSION['sid'])))
{
put here your codes for ses expire
}
}
ok mate thnaks for this code i try to edit session expire if low phones can handle this if((empty($_SESSION['sid']) OR (!isset($_SESSION['sid'] ahehehe -up- thanks!!!!
kabooms wrote: i allready try this code and i work good ahehhehe
if(($action != "") && ($action!="terms") && ($action!="gviewfrm") && ($action!="gviewcat") && ($action!="gviewtpc") && ($action!="gforumindx")) { $uid = getuid_sid($sid); if((empty($_SESSION['sid']) OR (!isset($_SESSION['sid']))) { put here your codes for ses expire } }ok mate thnaks for this code i try to edit session expire if low phones can handle this if((empty($_SESSION['sid']) OR (!isset($_SESSION['sid'] ahehehe -up- thanks!!!!
you may also try to add the old one, like this..
if((empty($_SESSION['sid'])||(!isset($_SESSION['sid']))||(islogged($sid)=="false")||($uid=="0"))
ok?..That's how pinoy rockz!!!Hehehe..I'm working for a new script and i'm going to remove ses id from url..Also put wml and html codes in 1 file..Auto-detect if supports html then header and footer returns html codes..Else, return wml codes..So that i wudn't be tired of doing separate codes and directories for wap and web
My Blog: http://jhommark.blogspot.com My Facebook: http://www.facebook.com/jhommark My Official Site: http://www.undergroundweb.tk My Community Site: http://undergroundwap.xtreemhost.com
where add this code
if(($action != "") && ($action!="terms") && ($action!="gviewfrm") && ($action!="gviewcat") && ($action!="gviewtpc") && ($action!="gforumindx"))
{
$uid = getuid_sid($sid);
if((empty($_SESSION['sid']) OR (!isset($_SESSION['sid'])))
{
put here your codes for ses expire
}
}
kiLLeR-eyEd_14 wrote: if((empty($_SESSION['sid'])||(!isset($_SESSION['sid']))||(islogged($sid)=="false")||($uid=="0"))
thankz mate wow nice idea. Will you share it us? Hmm i think it like funmobile script wml and xhtml in 1 file.. Bro killer eyed can i ask for a code about registration, password send via email can u help me ?Pls pm me..Thankz..
kabooms wrote: thankz mate wow nice idea. Will you share it us? Hmm i think it like funmobile script wml and xhtml in 1 file.. Bro killer eyed can i ask for a code about registration, password send via email can u help me ?Pls pm me..Thankz..
that's very easy, but b4 u make it, ur webhost must support the php mail() function..I've done coding it in my site a month ago..
My Blog: http://jhommark.blogspot.com My Facebook: http://www.facebook.com/jhommark My Official Site: http://www.undergroundweb.tk My Community Site: http://undergroundwap.xtreemhost.com
if(($action != "") && ($action!="terms") && ($action!="gviewfrm") && ($action!="gviewcat") && ($action!="gviewtpc") && ($action!="gforumindx")) { $uid = getuid_sid($sid); if((empty($_SESSION['sid']) OR (!isset($_SESSION['sid']))) { put here your codes for ses expire } }
Where Can I add this script?
LESS TALK. LESS MISTAKE.
HTTP://APPSROB.COM - LIST OF MY FACEBOOK APPS!
robzky wrote: Where Can I add this script?
on every page or file.,to know if session really starts and set.,else return ses expire..
My Blog: http://jhommark.blogspot.com My Facebook: http://www.facebook.com/jhommark My Official Site: http://www.undergroundweb.tk My Community Site: http://undergroundwap.xtreemhost.com
kiLLeR-eyEd_14 wrote: that's very easy, but b4 u make it, ur webhost must support the php mail() function..I've done coding it in my site a month ago..
yah bro killer eyed i will buy a 1year webhosting this coming 23 or 24 of july here at makati medyo mahal pero cguro okey naman bka may ma offer ka n mura n webhost jan al0ng manila kita tau i paid u cash or bank? Ok lng bro na pa copy naman ng register password send by email need q kc para iwas pasaway na wapper.. The code work like an angel i try in my wamp server .Thankz...
kiLLeR-eyEd_14 wrote: on every page or file.,to know if session really starts and set.,else return ses expire..
-Ive Got it.. thanks Killer-eyed..
LESS TALK. LESS MISTAKE.
HTTP://APPSROB.COM - LIST OF MY FACEBOOK APPS!
kabooms wrote: yah bro killer eyed i will buy a 1year webhosting this coming 23 or 24 of july here at makati medyo mahal pero cguro okey naman bka may ma offer ka n mura n webhost jan al0ng manila kita tau i paid u cash or bank? Ok lng bro na pa copy naman ng register password send by email need q kc para iwas pasaway na wapper.. The code work like an angel i try in my wamp server .Thankz...
pgka2alam q mer0n na t0pic nyan dto.,search mu na lng..
My Blog: http://jhommark.blogspot.com My Facebook: http://www.facebook.com/jhommark My Official Site: http://www.undergroundweb.tk My Community Site: http://undergroundwap.xtreemhost.com
kiLLeR-eyEd_14 wrote: This is what i've done successfully.. In core.php put this
session_start(); $sid = $_SESSION['sid'];
on top or bottom then in login.php find
$sid = md5($did);
and change it to
$_SESSION['sid'] = md5($did); $sid = $_SESSION['sid'];
observe it..After defining $_SESSION['sid'] as an md5($did) then define $sid as $_SESSION['sid'] so that it means $sid = $_SESSION['sid'] while the value of $_SESSION['sid'] = md5($sid); then on every page, you don't need to put something 'cause the session_start() and $sid = $_SESSION['sid'] is already in core.php and core.php is already included on every page..You just need to remove all $sid = $_GET['sid'] and all &sid=$sid..To display if not logged in or session expired i made this code
if(($action != "") && ($action!="terms") && ($action!="gviewfrm") && ($action!="gviewcat") && ($action!="gviewtpc") && ($action!="gforumindx")) { $uid = getuid_sid($sid); if((empty($_SESSION['sid']) OR (!isset($_SESSION['sid']))) { put here your codes for ses expire }
}then to destroy session, put this on top or bottom of the msg successfully logged out,
unset($_SESSION['sid']); $_SESSION = array(); session_destroy();
plz help me to add this code in action=logout
unset($_SESSION['sid']);
$_SESSION = array();
session_destroy();
one problm is there m successfully login bt i cant c owner cp also delete option of shout in main page y ownercp option is hide plz fix dis prblm
guest can enter the site if ryt url hummingbird feeder tube urs classic at ursite.com there is nothing show ur session id expire also this code show error parse error { sign creating prblm
if(($action != "") && ($action!="terms") && ($action!="gviewfrm") && ($action!="gviewcat") && ($action!="gviewtpc") && ($action!="gforumindx"))
{
$uid = getuid_sid($sid);
if((empty($_SESSION['sid']) OR (!isset($_SESSION['sid'])))
{
put here your codes for ses expire
}
}
kazzin wrote: plz help me to add this code in action=logout
unset($_SESSION['sid']); $_SESSION = array(); session_destroy();one problm is there m successfully login bt i cant c owner cp also delete option of shout in main page y ownercp option is hide plz fix dis prblm
try using the function isowner($uid) c0z that's also my pr0b and i s0lved it by using that
My Blog: http://jhommark.blogspot.com My Facebook: http://www.facebook.com/jhommark My Official Site: http://www.undergroundweb.tk My Community Site: http://undergroundwap.xtreemhost.com
Why do you need to make session protection for lavalair ?? You can make
$browser[0] = select browser from ..._users;
$nowbrowser = getbrowser();
if ($browser[0]!==$nowbrowser)
{
LOGOUT USER
}
The same thing can be made for IP too ..
whatmp3.name - search mp3 on mobile
shad0w wrote: Why do you need to make session protection for lavalair ?? You can make
$browser[0] = select browser from ..._users; $nowbrowser = getbrowser(); if ($browser[0]!==$nowbrowser) { LOGOUT USER }The same thing can be made for IP too ..
its a not god idea 😊
kazzin wrote: guest can enter the site if ryt url hummingbird feeder tube urs classic at ursite.com there is nothing show ur session id expire also this code show error parse error { sign creating prblm
if(($action != "") && ($action!="terms") && ($action!="gviewfrm") && ($action!="gviewcat") && ($action!="gviewtpc") && ($action!="gforumindx")) { $uid = getuid_sid($sid); if((empty($_SESSION['sid']) OR (!isset($_SESSION['sid']))) { put here your codes for ses expire } }
add islogged($sid)==false OR $uid==0 then ses expire
My Blog: http://jhommark.blogspot.com My Facebook: http://www.facebook.com/jhommark My Official Site: http://www.undergroundweb.tk My Community Site: http://undergroundwap.xtreemhost.com
Why to modify the whole script when you can make ip/browser protection ....
whatmp3.name - search mp3 on mobile