Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#109 2014-04-04 16:48:43

CeBe
Plugin Author
From: Caen - Fr
Registered: 2010-06-25
Posts: 345
Website

Re: cbe_frontauth: Connect to (and disconnect from) backend from frontend

Is it related to forum.textpattern.com/viewtopic.php?pid=280055#p280055 ?
If it is, I confirm that there is something missing : last login date is not set, and it definitely should >_<

Now, more precisely about your question : if you can tell when someone logs in, it’s more difficult to tell when (s)he leaves. If (s)he logs out, you can say that (s)he leaves… but (s)he can leave without logging out and you then have to perform some sort of magic to determine whether (s)he is still here or not.

But let me first fix this stupid last access bug.

Offline

#110 2014-04-04 17:05:05

fiddle
Member
Registered: 2007-10-03
Posts: 87

Re: cbe_frontauth: Connect to (and disconnect from) backend from frontend

Hi…
Yes it is, I was trying to find a way around that issue, but if your plugin get the info from the same lace, guess it would not resolve it….
It is weird, it works on some logins, but not others.. I created an account to test it, made sure I logged on and off, multiple times, but never shoes any last logon info…

Not the biggest deal really, wanted to keep tabs on users, but can live without…

Thank you for the help..
Fidel

Offline

#111 2014-04-04 17:22:58

CeBe
Plugin Author
From: Caen - Fr
Registered: 2010-06-25
Posts: 345
Website

Re: cbe_frontauth: Connect to (and disconnect from) backend from frontend

V0.9.5 can now be downloaded. It fixes the bug described above (last login date not set in database).
Sorry for the inconvenience.

For those who want to know :
As Stef mentioned, I use core functions. The one which stores this date is txp_validate() but it was called with the last parameter (whether to store login date or not) set to FALSE o_O and I really don’t remember why.

ETA, Apr 7: it is v0.9.6 now, another bug has been reported.

Last edited by CeBe (2014-04-07 15:45:18)

Offline

#112 2014-04-04 17:31:28

fiddle
Member
Registered: 2007-10-03
Posts: 87

Re: cbe_frontauth: Connect to (and disconnect from) backend from frontend

Thank you Claire, looks good so far.. Tried log on log off with the test account that was not updating.. Now it is…
Thank you so much for the quick fix..

Offline

#113 2014-10-27 12:47:09

milosevic
Member
From: Madrid, Spain
Registered: 2005-09-19
Posts: 390

Re: cbe_frontauth: Connect to (and disconnect from) backend from frontend

Hi Claire:

It will be nice if you could add a param (perhaps named “placeholder”) to cbe_frontauth functions to define placeholder params for de inputs. I don’t find the way to this with the plugin:

<input type="text" name="p_userid" placeholder="enter your username here" ... /> 
<input type="password" name="p_password" placeholder="enter your password here" ... />

Anyway it’s a super nice plugin! Thanks a lot.


<txp:rocks/>

Offline

#114 2014-10-29 20:52:06

etc
Developer
Registered: 2010-11-11
Posts: 5,028
Website GitHub

Re: cbe_frontauth: Connect to (and disconnect from) backend from frontend

Why wouldn’t you just insert it with etc_query:

<txp:etc_query data="cbe_frontauth tags"
	replace="//input[@name='p_userid']@@placeholder=enter your username here;
		//input[@name='p_password']@@placeholder=enter your password here" />

You can alter any attribute of any tag this way.

Offline

#115 2014-11-01 13:06:46

milosevic
Member
From: Madrid, Spain
Registered: 2005-09-19
Posts: 390

Re: cbe_frontauth: Connect to (and disconnect from) backend from frontend

etc wrote #285226:

Why wouldn’t you just insert it with etc_query:

<txp:etc_query data="cbe_frontauth tags"...

Nice method! I have hardcoded my inputs but I’ll give it a try, thanks.


<txp:rocks/>

Offline

#116 2015-03-24 12:56:52

NicolasGraph
Plugin Author
From: France
Registered: 2008-07-24
Posts: 860
Website

Re: cbe_frontauth: Connect to (and disconnect from) backend from frontend

Hi,

Does anyone tried to use aks_header with cbe_frontauth?
I had a problem with the cbe_frontauth_logout tag when gzip was set to 1 in aks_header.
Both Firefox and Chrome display an encoding error when “logout” is clicked.
I removed the link but I thought it could be useful to report that…

Another thing is that when I logged out, the protected content continued to be display untill the page was refreshed. Is it normal?

Anyway, thanks Claire for this useful and easy to use plugin.


Nicolas
Follow me on Twitter and GitHub!
Multiple edits are usually to correct my frenglish…

Offline

#117 2015-04-21 15:33:08

hilaryaq
Plugin Author
Registered: 2006-08-20
Posts: 335
Website

Re: cbe_frontauth: Connect to (and disconnect from) backend from frontend

Is there anyway to restrict access to a specific email address within the frontauth tag please? So one a single specific user can access something? Thanks!


…………………
I <3 txp
…………………

Offline

#118 2015-04-22 20:56:32

CeBe
Plugin Author
From: Caen - Fr
Registered: 2010-06-25
Posts: 345
Website

Re: cbe_frontauth: Connect to (and disconnect from) backend from frontend

NicolasGraph wrote #289350:

Does anyone tried to use aks_header with cbe_frontauth?

I must admit that I didn’t…

Both Firefox and Chrome display an encoding error when “logout” is clicked.
I removed the link but I thought it could be useful to report that…

I’m planning to host the plugin on GitHub, so that anyone can fix bugs and improve it. I don’t have time for plugins at the moment :(

Another thing is that when I logged out, the protected content continued to be display untill the page was refreshed. Is it normal?

Not sure. Have you tried the <txp:cbe_frontauth_redirect /> tag ?

<txp:cbe_frontauth_redirect
    for="login | logout | login,logout"
    value="after_login_url | after_logout_url | after_login_url,after_logout_url" />
hilaryaq wrote #290149:

Is there anyway to restrict access to a specific email address within the frontauth tag please? So one a single specific user can access something? Thanks!

A user can login with his username or his email and it is automatically detected.
Then you can retrieve his name and restrict access on content using:
(warning :) untested!)

<txp:cbe_frontauth_protect name='<txp:cbe_frontauth_whois type="name" />'>
  What to protect
<txp:else />
  What to display if not connected
</txp:cbe_frontauth_protect>

Offline

#119 2015-04-23 14:44:50

hilaryaq
Plugin Author
Registered: 2006-08-20
Posts: 335
Website

Re: cbe_frontauth: Connect to (and disconnect from) backend from frontend

Thanks Claire! :) You are a legend for this plugin, it’s so handy!


…………………
I <3 txp
…………………

Offline

#120 2015-04-23 20:09:17

CeBe
Plugin Author
From: Caen - Fr
Registered: 2010-06-25
Posts: 345
Website

Re: cbe_frontauth: Connect to (and disconnect from) backend from frontend

Huhu… Thank you :)
And thanks to Pat64 too, who had the idea.

The plugin is now hosted on Github.

Last edited by CeBe (2015-04-23 20:10:30)

Offline

Board footer

Powered by FluxBB