This forum has been moved here:
Helicon Tech Community Forum

  Active TopicsActive Topics  Display List of Forum MembersMemberlist  HelpHelp   RegisterRegister  LoginLogin
Helicon Ape
 Helicon Tech : Helicon Ape
Subject Topic: Need to remove space before a slash Post ReplyPost New Topic
Author
Message << Prev Topic | Next Topic >>
kwheat99
Newbie
Newbie


Joined: 27 May 2010
Location: United States
Online Status: Offline
Posts: 11
Posted: 27 January 2012 at 1:45pm | IP Logged Quote kwheat99

Hello,

We have a search engine that is putting a space in our urls that and getting a 404. They are doing something like this...

http://domain/oh/cincinnati/con-article/654043/cancer /article.htm

Notice the space after the word cancer and before the /. It, however, works if the space is before the word cancer 654030/ cancer/...

The word cancer is the optional (?:\&query=([^&]+)) in the below rule

Here is the rule:
SeoRule articlepage_cn.aspx\?cn-documentid=([^&]+)&s=([^&]+)&cat=([^&]+)(?:\&query=([^&]+))?$ /${mapStates:$2}/${mapCities:$2}/$3-article/$1/(?4$4/)${slug:${SeoHDTitle:$1}}.htm [Redirect, Scope=A]
RewriteRule ^([^-/]+)/([^/]+)/([^/]+)-article/([^-/]+)/(?:([^/]+)/)([^/]+).htm$ /articlepage_cn.aspx\?cn-documentid=$4&s=${revmapSites:$2-$1}&cat=$3&query=$5 [NC,L]

I've tried several things with \s and %20 and LP, NE rules but nothing is working.
Any suggestions?
Thanks
Kelton

Back to Top View kwheat99's Profile Search for other posts by kwheat99 Visit kwheat99's Homepage
 
Guests
Guest
Guest


Joined: 01 October 2003
Online Status: Online
Posts: -149
Posted: 30 January 2012 at 6:22am | IP Logged Quote Guests

Have you tried the following:

Code:
RewriteRule (\S+)(?:\s|%20)(.*) $1$2 [NC,R=301,LP,L]


Regards
Andrew

Edited by AndrushkaUS - 30 January 2012 at 6:24am
Back to Top View Guests's Profile Search for other posts by Guests
 

If you wish to post a reply to this topic you must first login
If you are not already registered you must first register

  Post ReplyPost New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You can vote in polls in this forum