Welcome Guest, Not a member yet? Register   Sign In
Is there a way i can access the session data of another application?
#11

[eluser]InsiteFX[/eluser]
You will need away to see which user is logged in for checking.

Do both application use the same user id otherwise you would need to pass their email address or
something for looking up their database record for checking.

App1:
When user logs in set a cookie with the information to pass to app2.

App2:
Read the passed cookie from app1 and check the users information.
#12

[eluser]lalay[/eluser]
only app1 uses log in. app2 does not
#13

[eluser]lalay[/eluser]
so, app2 needs to know if someone is logged in in app1. if there is no one logged in, app2 will not run.
#14

[eluser]InsiteFX[/eluser]
Correct.
#15

[eluser]lalay[/eluser]
i think i got it!

i just need to know now if I could redirect it to app1's login page. is that possible?

btw, this worked for me: $log = $this->input->cookie('cookiename', TRUE);
if($log) echo "yes!"; else echo "no Sad";
i just got the spelling of the cookie wrong so it was getting errors. I'm so sorry for the stupid mistake Sad
#16

[eluser]InsiteFX[/eluser]
You would need to use an html anchor for that.
Code:
<a href="http://www.your.com/controller/function">App1</a>
#17

[eluser]lalay[/eluser]
how about if I use the redirect function?
#18

[eluser]InsiteFX[/eluser]
You can try it but I do not think it will work!
#19

[eluser]lalay[/eluser]
yes i see. that's my problem right now. I can't redefine the basepath to redirect. is it possible to redefine the basepath? i haven't got any luck with google search so far.




Theme © iAndrew 2016 - Forum software by © MyBB