PC SOFT

FORUMS PROFESSIONNELS
WINDEVWEBDEV et WINDEV Mobile

Accueil → WEBDEV 2024 → Login in PHP
Login in PHP
Débuté par Kim O'Regan, 26 aoû. 2010 22:30 - 3 réponses
Posté le 26 août 2010 - 22:30
Hi
Since Groupware doesn't work with PHP pages, is there any other way to easily handle login and access to pages, or do you have to code it yourself?
Any suggestions how that would look?

Thanks!
/Kim
Membre enregistré
14 messages
Posté le 04 décembre 2010 - 08:17
Hi Kim

you actually have to code it yourself. But this is a pretty easy thing to do:

- declare some global variables that you will need all along the session (these will be your session variables)

- you have to build a "login" page where you will check user credentials and rights, and initialize your session variables then direct the user to whatever page you need.

- in the Init of each page (best if you include this in your page model), add a couple of lines that test if your current user name is empty. If so, call a global procedure that resets all session variables and then redirect the user to the login page (using PageUtilize in order to reset page contexts)

I hope it helped.

Good luck!
Renaud
Membre enregistré
6 messages
Posté le 11 décembre 2010 - 18:24
Thanks, I thought it would be something like that but I just got WebDev 16 and it seems like groupware now works with PHP. The RAD also supports CMS, blog, forums etc which should include login (at least the "associatif" RAD. It will be a lot easier when the english version arrives... ;-)

Regards,
Kim
Membre enregistré
9 messages
Posté le 13 décembre 2010 - 09:22
Cool. Good for you!
I wanted to get Win/WebDev 16 before year end but that will not be possible. I hope the new version is worth it - apparently you already found what you are looking for :o)

Have a good one!
Renaud