Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#316 2007-01-19 22:07:48

infusion
Member
Registered: 2005-08-04
Posts: 19

Re: ign_password_protect

Thanks for your reply igner. But the thing is…. I’m using the txp users and have successfully changed the password for it. And I log in using this new password but when I’m at the protected section, the new password gets rejected. How do I check or fix what’s wrong?

Offline

#317 2007-01-19 22:12:49

igner
Plugin Author
Registered: 2004-06-03
Posts: 337

Re: ign_password_protect

what version of the plugin are you using?


And then my dog ate my badger, and the love was lost.

Offline

#318 2007-01-19 22:21:08

infusion
Member
Registered: 2005-08-04
Posts: 19

Re: ign_password_protect

0.4.2d

Offline

#319 2007-01-20 13:41:18

infusion
Member
Registered: 2005-08-04
Posts: 19

Re: ign_password_protect

One more thing igner….. I’m not sure if this is a bug or a feature but I’ve inserted these 2 code fragments to 2 different articles to mutually exclude 1 group from another.

Article 1:
<code>
<txp:ign_if_not_logged_in privs=“6”>You are trying to access a password protected page. Please log in or sign up by clicking the link below.
</txp:ign_if_not_logged_in>
</code>

Article 2:
<code>
<txp:ign_if_not_logged_in privs=“5”>You are trying to access a password protected page. Please log in or sign up by clicking the link below.
</txp:ign_if_not_logged_in>
</code>

But given the scenario that I logged in with priv 5 (Article 2) and tried accessing the protected area for priv 6 (Article 1), the message that it is a password protected page does not come up. If i’m not wrong, it labels me as being logged in. However I want the message to show up as long as he’s not logged in as a priv 6 user. Vice versa is true as well.

Any suggestions?

Offline

#320 2007-01-22 13:51:22

igner
Plugin Author
Registered: 2004-06-03
Posts: 337

Re: ign_password_protect

That’s really a shortcoming in previous versions. You are logged in, but don’t have sufficient privileges, so the content’s swallowed.

I’ve strived to address that in the 0.5 version that’s currently in beta, if you want to give that a shot.


And then my dog ate my badger, and the love was lost.

Offline

#321 2007-01-22 22:35:06

mrdale
Member
From: Walla Walla
Registered: 2004-11-19
Posts: 2,215
Website

Re: ign_password_protect

>igner

Quick Question: Is there a way to output in plain text the user’s email?

Detailed Thanks: Thanks to your plugin and wondertag, I got my client section set up and it works really well. All I have to do to set up a new client is add an account with no rights, and add pertinent client categories (image, article, file, etc.).

As a user logs in, he is greeted with a summary page listing:
  1. A personal greeting with name user name and logout info.
  2. A list of recent developments that have been accomplished for them (with detail pages)
  3. A collapsible sidebar menu that contains:
    • A small calendar (with a link to the large detailed one) that visually shows progress/deadlines
    • A small email form with their name pre-filled
    • Upcoming deadlines
    • Files and Proofs
    • Image galleries
    • Upload form (coming soon)

It all seems to work. And it’s all client-specific. I even figured out some conditional logic to keep one user out of another user’s permlinks if they are smart enough to guess them.

I’m thinking about posting a how-to somewhere…

Just thought I’d say thanks again.

Last edited by mrdale (2007-01-22 22:35:43)

Offline

#322 2007-01-22 22:46:28

igner
Plugin Author
Registered: 2004-06-03
Posts: 337

Re: ign_password_protect

mrdale: try <txp:ign_user_info type="email" /> :)

looking forward to seeing that writeup – maybe in the interim I’ll have time to finish the documentation on the current version!


And then my dog ate my badger, and the love was lost.

Offline

#323 2007-01-22 22:48:36

mrdale
Member
From: Walla Walla
Registered: 2004-11-19
Posts: 2,215
Website

Re: ign_password_protect

igner wrote:

mrdale: try <txp:ign_user_info type="email" /> :)

Is this specific to the 5.0b or has it been around all along? Does it output the email in plain text?

Offline

#324 2007-01-22 23:17:48

mrdale
Member
From: Walla Walla
Registered: 2004-11-19
Posts: 2,215
Website

Re: ign_password_protect

Hey, tried it out and I got a very interesting “woo hoo” message on login. :)

Last edited by mrdale (2007-01-22 23:40:21)

Offline

#325 2007-01-23 01:23:40

igner
Plugin Author
Registered: 2004-06-03
Posts: 337

Re: ign_password_protect

er, you must certainly have gotten a bad download – there’s no way any of my code would say that.

re-download and you should be set. ;)


And then my dog ate my badger, and the love was lost.

Offline

#326 2007-01-23 01:26:36

szac
Member
From: Detroit-ish
Registered: 2004-09-18
Posts: 50

Re: ign_password_protect

mrdale, a write about that method would be AWESOME! I hit the forums today specifically looking for a way to do what you just described!

And yes, the wondertag was a game changer for me as well. easily managed 3 tier navigation, etc… Lovin it!

Offline

#327 2007-01-23 02:26:20

mrdale
Member
From: Walla Walla
Registered: 2004-11-19
Posts: 2,215
Website

Re: ign_password_protect

>igner
Woo Hoo! ;)

It’s almost working for me. Right now <txp:ign_logout_link> produces a link with no text <a href='?logout=1'alt='Logout'title='Logout'></a>. I’d really like it to say “log out, ladies” or something.

[edit]
OK, I hacked the plugin to allow the user to specify the logout link text as an attribute. Yay! Could you incorporate this (or the function thereof) in your next release?

Here’s what I did:

Find

$o[] = ">$thing</a>";

Replace it with

$o[] = ">";
$o[] = (!empty($linktext)) ? "$linktext" : '';
$o[] = "</a>";

Then Find

'id' => ''

Replace it with

'id' => '',
'linktext' => 'log out'

Last edited by mrdale (2007-01-23 02:51:45)

Offline

#328 2007-01-23 03:40:54

igner
Plugin Author
Registered: 2004-06-03
Posts: 337

Re: ign_password_protect

actually, the way it was in the release, usage would be <txp:ign_logout_link>Logout link text</txp:ign_logout_link>. It’s part of the whole move to forms for all localization (you can incorporate the logout link however you want, wherever you want. What I neglected to do was add default text if using the self-closing form, and some built in logic to not display if not logged in. (Right now you’d need to wrap it in if_logged_in conditionals).

That’s a nice addtion, though my whole train of thought here is that I want to NOT use attributes for these sorts of things, if for no other reason than it makes the tags more cryptic for the lay person.

Of course, it’s not easy if there’s no documentation :)


And then my dog ate my badger, and the love was lost.

Offline

#329 2007-01-23 04:39:53

mrdale
Member
From: Walla Walla
Registered: 2004-11-19
Posts: 2,215
Website

Re: ign_password_protect

Fair enough. conatiner tag it is then.

Unhacking…

Last edited by mrdale (2007-01-23 04:40:24)

Offline

#330 2007-01-23 05:08:42

igner
Plugin Author
Registered: 2004-06-03
Posts: 337

Re: ign_password_protect

in the spirit of obfuscation, what I’ll do is allow for a linktext attribute as a fallback if $thing is empty, then fall back to a constant if both are empty. That way it’ll be impossible to generate an empty link, as happens now. nothing like three ways to do one thing :)


And then my dog ate my badger, and the love was lost.

Offline

Board footer

Powered by FluxBB