Textpattern Forum

You are not logged in. Register | Login | Help

#521 2009-11-03 13:57:07

maniqui
Moderator
From: Buenos Aires, Argentina
Registered: 2004-10-10
Posts: 2,989
Website

Re: gbp_permanent_links

OK, after a quick chat with graeme, he made me notice that that’s how thing work on the inner cogs of TXP, because:

because /section/category/title effectively means /?s=section&c=category&id=someid

And also:

/section/title?c=category is valid (returns true)

Even if the above URLs may not match any real use case, that’s how things works on the background. TXP evaluates if the &c=name ($c variable) is set, and so, if_category returns true, even if on an individual article.

The possible “workarounds”:

  • test for if_individual_article instead of testing for if_category
  • test for if_article_list first and then nest a if_category (aka “if_category_list” tag, yet to be invented).

Thanks, graeme!


La música ideas portará y siempre continuará

TXP Builders – finely-crafted code, design and txp

Offline

#522 2009-11-03 23:30:32

uli
Moderator
From: Cologne/Köln
Registered: 2006-08-15
Posts: 3,119

Re: gbp_permanent_links

Thanks for letting us know, Julián!


In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links

Offline

#523 2009-11-08 22:26:56

aswihart
Member
From: Pittsburgh, PA
Registered: 2006-07-22
Posts: 345
Website

Re: gbp_permanent_links

One issue I’m having for end-users, not sure if it’s specific to Txp 4.2: even wtih Freelancer privileges, I can see and edit the settings of this plugin in the Admin tab.

Offline

#524 2009-11-08 23:07:09

uli
Moderator
From: Cologne/Köln
Registered: 2006-08-15
Posts: 3,119

Re: gbp_permanent_links

Funny I never remarked that. Thanks for the heads-up!

In the gbp library look for:
@var $permissions = ’1,2,3,4,5,6’;@ (two instances)
change to the user levels that you need there.

See graeme’s post

Last edited by uli (2009-11-10 14:49:49)


In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links

Offline

#525 2009-11-10 02:16:49

aswihart
Member
From: Pittsburgh, PA
Registered: 2006-07-22
Posts: 345
Website

Re: gbp_permanent_links

Thanks mate! Yeah, I think it’s probably prudent to make it default to at least 1,2,3, if not just 1!?

Offline

#526 2009-11-10 14:11:24

graeme
Plugin Author
Registered: 2004-06-21
Posts: 337
Website

Re: gbp_permanent_links

uli wrote:

In the gbp library look for:
var $permissions = '1,2,3,4,5,6'; (two instances)
change to the user levels that you need there.

Instead of modifying the admin library can I suggest you define var $permissions = etc... in the PermanentLinks, PermanentLinksBuildTabView and PermanentLinksListTabView classes within the gbp_pl source. The admin library is used for other plugins (eg. MLP) so any changes made to it would also effect them too.

Offline

#527 2009-11-10 14:27:29

uli
Moderator
From: Cologne/Köln
Registered: 2006-08-15
Posts: 3,119

Re: gbp_permanent_links

graeme wrote:

The admin library is used for other plugins (eg. MLP) so any changes made to it would also effect them too.

Ouch! Thanks


In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links

Offline

#528 2009-11-14 17:13:28

aswihart
Member
From: Pittsburgh, PA
Registered: 2006-07-22
Posts: 345
Website

Re: gbp_permanent_links

Any tips on getting this plugin to play nice with jmd_rate? See my issues in that plugin’s thread.

Offline

#529 2009-11-14 23:44:06

aswihart
Member
From: Pittsburgh, PA
Registered: 2006-07-22
Posts: 345
Website

Re: gbp_permanent_links

I have clean search result urls working, but how do you get <txp:search_input /> to send you to them instead of the messy ones?

Offline

#530 2009-11-15 08:34:12

candyman
Member
From: Italy
Registered: 2006-08-08
Posts: 514

Re: gbp_permanent_links

graeme wrote:

Instead of modifying the admin library can I suggest you define var $permissions = etc... in the PermanentLinks, PermanentLinksBuildTabView and PermanentLinksListTabView classes within the gbp_pl source. The admin library is used for other plugins (eg. MLP) so any changes made to it would also effect them too.

True. It would be possible to upgrade the plugin with the new restricted permissions? I think that is better that only the admin can define the Links by default.

Offline

Board footer

Powered by FluxBB