Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
#169 2006-09-23 14:17:49
Re: [plugin] [ORPHAN] zem_rewrite: configurable clean URLs
Mary wrote:
> “Is this supposed to work with v4.0.x?”
No.
It does for me….mostly.
We were faced with a problem whereby we wanted our site to be listed in Google News, which requires a three digit number in the URL for it to index the articles. Unfortunately, the site was already well established with clean urls in the /section/title format.
While changing to /section/id/title
would solve the Google News indexing problem, it would break all existing links from external sites. What we needed was to set the preferences to /section/id/title
for internal links, yet still allow /section/title
external links. The number of external links to deep articles meant that using .htaccess redirects for each article would be impractical.
I did the following:
(i) Installed and switched on zem_rewrite 0.6
(ii) edited zem_rewrite to
<code>
$uri_scheme[‘article’] = ‘{section}/{article}/{title}’;
$uri_scheme[‘article_alt’] = ‘{section}/{url_title}’;
$uri_scheme[‘category’] = ‘{section}/{category}/’;
$uri_scheme[‘section’] = ‘{section}/’;
</code><br/>
(iii) Changed Permanent link mode to /section/id/article
This works perfectly with both /section/title and /section/id/title URLs being able to be used interchangeably. However, this now breaks the rss and atom feeds with, say, /rss?limit=25
being passed to the 404 page.
I have tried adding
$uri_scheme['rss'] = 'rss'
to no effect.
I appreciate this plugin is not likely to be supported anymore – but is there an edit or hack which would make zem_rewrite pass /rss
and /atom
links back to TXP rather that to 404 ? Or is there another, direct, link to the RSS and Atom links I could use ?
Any help would be much appreciated,
~Nick
Last edited by NickML (2006-09-23 15:37:45)
Offline
#170 2006-09-23 17:48:49
Re: [plugin] [ORPHAN] zem_rewrite: configurable clean URLs
I wrote:
I have tried adding
$uri_scheme['rss'] = 'rss'
to no effect.
It turned out that the order I’d put it was wrong: this appears to work perfectly:
<code>$uri_scheme[‘article’] = ‘{section}/{article}/{title}’;
$uri_scheme[‘article_alt’] = ‘{section}/{url_title}’;
$uri_scheme[‘category’] = ‘{section}/{category}/’;
$uri_scheme[‘rss’] = ‘rss/’;
$uri_scheme[‘atom’] = ‘atom/’;
$uri_scheme[‘section’] = ‘{section}/’;
</code><br/>
~Nick
Offline
#171 2007-04-07 16:20:32
Re: [plugin] [ORPHAN] zem_rewrite: configurable clean URLs
Useful plugin!
One question:
Isn’t it possible to show the default txp error page instead of “The page you requested, [page], was not found.”?
Would be the most logical method.
Thanks, Jan
Kensington TXP powered rock
Offline
#172 2008-09-01 16:38:58
Re: [plugin] [ORPHAN] zem_rewrite: configurable clean URLs
Haha, just saw my old post:
Solution is quite simple… just comment out the if-conditional around line #100 which initiates a header redirect to a “404 page” when the entered url points to nowhere. Wrong urls will then trigger your default 404 page.
There’s another compelling reason to comment these lines out, because the plugin’s error page is a so-called soft 404, i.e. an error page which actually sends a 200 (OK) header instead of the desirable 404 (NOT FOUND) header.
I discovered this since my client’s website didn’t show up in Google. (Google doesn’t like false 404s).
Last edited by jan (2008-09-01 16:39:24)
Kensington TXP powered rock
Offline
#173 2011-01-11 16:06:57
Re: [plugin] [ORPHAN] zem_rewrite: configurable clean URLs
Anything like this available for TXP 2.30?
Offline
#174 2011-01-11 17:59:13
- els
- Moderator
- From: The Netherlands
- Registered: 2004-06-06
- Posts: 7,458
Re: [plugin] [ORPHAN] zem_rewrite: configurable clean URLs
4.3.0? ;) Probably gbp_permanent_links.
Offline
#175 2011-01-11 18:07:13
Re: [plugin] [ORPHAN] zem_rewrite: configurable clean URLs
Thanks very much Els, I’ll have a look at gbp_permanent_links.
Not sure where the 2 came from – I’ve been a TXP user since the early days and know the major version number started out at 4!
Offline
#176 2013-01-16 08:35:03
- christian13467
- New Member
- From: Glienicke, Germany
- Registered: 2013-01-16
- Posts: 1
Re: [plugin] [ORPHAN] zem_rewrite: configurable clean URLs
Does anyone know if zem_rewrite will be further maintained. I used it a long time at txp 4.0.6 sites.
Now I plan to upgrade my sites to 4.5 and look for current versions of my used plugins.
Are there any alternatives?
Christian
Offline
#177 2013-01-16 09:58:15
Re: [plugin] [ORPHAN] zem_rewrite: configurable clean URLs
Hi Christian,
I think that Stef (aka Bloke), is or has plans to maintain it.
Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.
Offline