Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
#91 2006-12-23 19:13:29
- Andrew
- Plugin Author

- Registered: 2004-02-23
- Posts: 730
Re: gbp_permanent_links
Any tips yet as to how to solve the Non-static method PermanentLinksBuildTabView error?
Offline
#92 2006-12-23 19:48:42
- Andrew
- Plugin Author

- Registered: 2004-02-23
- Posts: 730
Re: gbp_permanent_links
My guess is it’s a fairly simple fix that involves syntax changes for php5?
Offline
Re: gbp_permanent_links
Really slick plugin, Greame,
Nice attention to detail on the interface. Just want to second the request for categories other than articles being supported. That’s the only thing that keeps me using the ‘old as the hills’ sgb_url_handler’.
I’m really impressed though. good work, especially from a usability perspective.
Offline
#94 2006-12-23 20:28:20
- Andrew
- Plugin Author

- Registered: 2004-02-23
- Posts: 730
Re: gbp_permanent_links
Are the nested functions the source for the fatal errors in PHP5?
class PermanentLinksBuildTabView extends GBPAdminTabView
{
function preload()
{
[...]
}
function main()
{
[...]
function gbpFLabel( $label, $contents='', $label_right=false )
{
// This function is nested... is this legal in PHP5?
Offline
Re: gbp_permanent_links
Andrew wrote:
Are the nested functions the source for the fatal errors in PHP5?
Probably, I’m working on it now along with a couple of other bugs. Should have something up in a couple of hours…
Offline
Re: gbp_permanent_links
I’ve set omit_trailing_slash to no. But somehow google indexed some urls without the trailing slash.
My permanent links are built like this: section/title/
I noticed if I type in a section/title url in the adres bar it works as well.
So I want any faulty external section/title link to be either redirected with a 301 to section/title/ or given a 404. Is this possible, I’ve tried mod_rewrite but couldn’t get it to work.
Offline
#97 2006-12-24 01:49:47
- Andrew
- Plugin Author

- Registered: 2004-02-23
- Posts: 730
Re: gbp_permanent_links
You can force a trailing slash with .htaccess with this set of rules (must be placed before your default Textpattern rules):
# force trailing slash
RewriteCond %{REQUEST_URI} /+[^\.]+$
RewriteRule ^(.+[^/])$ /$1/ [R=301,L]
Offline
Re: gbp_permanent_links
Okay here is the next version gbp_permanent_links_0.11 c
This should fix all the issues currently listed on this thread.
- Added a new redirection preference for mt style links #
- Fixed the
$pg# - Fixed bugs with the prefix and suffix output and suffix matching #
- Removed nested functions to fix the
Non-static method PermanentLinksBuildTabViewerrors # - Fixed permlinks, so they use the full url in RSS and ATOM feeds #
- Fixed a bug where older, newer archive links weren’t being displayed correctly on the front page
- And hopefully fixed the ‘random sections’ error #
Thanks to everyone who reported these bugs.
Offline
Re: gbp_permanent_links
bisk wrote:
I’ve set omit_trailing_slash to no. But somehow google indexed some urls without the trailing slash.
My permanent links are built like this: section/title/
I noticed if I type in a section/title url in the adres bar it works as well.
So I want any faulty external section/title link to be either redirected with a 301 to section/title/ or given a 404. Is this possible, I’ve tried mod_rewrite but couldn’t get it to work.
The omit_trailing_slash preference value won’t effect whether a page is matched when the URL is with or without the trailing slash. It is only used when outputting links. I shall look into changing this for the future but for now Andrew’s solution looks sound.
Thanks Andrew.
Offline
#100 2006-12-24 02:29:26
- Andrew
- Plugin Author

- Registered: 2004-02-23
- Posts: 730
Re: gbp_permanent_links
Yep, no more error :)
Offline
#101 2006-12-24 02:31:35
- Andrew
- Plugin Author

- Registered: 2004-02-23
- Posts: 730
Re: gbp_permanent_links
Holy crap, this plugin rocks!
Offline
#102 2006-12-24 02:35:08
- Andrew
- Plugin Author

- Registered: 2004-02-23
- Posts: 730
Re: gbp_permanent_links
Hm… actually – I’m now getting an error on the public side:
Fatal error: Non-static method PermanentLinks::check_permlink_conditions() cannot be called statically … on line 711
(I don’t know if this would have been the case before the update, since I didn’t have the ability to create any permlink rules)
Offline
#103 2006-12-24 03:54:03
- Andrew
- Plugin Author

- Registered: 2004-02-23
- Posts: 730
Re: gbp_permanent_links
After browsing the source, my guess is that the same could also occur with PermanentLinksListTabView::nav_form() and PermanentLinksListTabView::pager()
(thanks for the help btw :)
Offline
#104 2006-12-24 08:16:49
- minimal design
- Member
- Registered: 2006-10-15
- Posts: 38
Re: gbp_permanent_links
hmmm… I finally get a chance to work on my site again and I just realized links to file downloads don’t work…
I get links like http://minimaldesign.net/file_download/projects#38;id=1 instead of http://minimaldesign.net/file_download/1
When I turn off the plugin, it works fine… I’m probably the one at fault but a pointer in the right direction would be appreciated ;)
my set up in the plugin prefs is pretty much the default, only one: section/category/title/
Thanks!
Offline
#105 2006-12-24 08:56:14
Re: gbp_permanent_links
Andrew wrote:
You can force a trailing slash with .htaccess with this set of rules (must be placed before your default Textpattern rules):
Thanks a lot. It’s working now :)
Offline