wilderness

msg:4324780 | 10:07 pm on Jun 10, 2011 (gmt 0) |
See this old thread [webmasterworld.com] and jdmorgan's explanation
|
rshandy

msg:4325507 | 3:33 pm on Jun 13, 2011 (gmt 0) |
Thanks, but after reviewing that thread it doesn't seem to have a correlation to what I'm trying to do. I'm using an a .htaccess file to perform permanent redirect either by using the RewriteCond, RewriteRule or Redirect permanent commands. I just can't seem to get anything to redirect that has a dash or a dot in the path. For example, using the Redirect permanent command I can do this: Redirect permanent /cgibin/SoftCartexe/scstore [123safe.com...] but it won't do this: Redirect permanent /cgi-bin/SoftCart.exe/scstore [123safe.com...] I also tried this: Redirect permanent /cgi-bin/SoftCart\.exe/scstore [123safe.com...] Apache must have some safeguard for cgi-bin and dots within a url string. I can using other hyphenated terms in the url string: Redirect permanent /try-this/scstore [123safe.com...] But not that has a "." in it or "cgi-bin" Any ideas? Thanks
|
wilderness

msg:4325520 | 4:01 pm on Jun 13, 2011 (gmt 0) |
The correlation is that your script is overriding/interfering with the htaccess, as jdmorgan explained. Either correct of disable your script entirely. Please refer to forum charter and use of example.com for domain names, otherwise the assistance your asking for us unable to read your syntax.
|
rshandy

msg:4325621 | 7:34 pm on Jun 13, 2011 (gmt 0) |
oops sorry, my bad. I was cutting and pasting from my .htaccess file. I re-read the thread and I'm hoping my situation is not that complicated. I just want to grab old links that were pointing to product pages that contain the string "cgi-bin/SoftCart.exe/scstore to /scstore. I'm NOT writing a script, I'm just putting the redirect in the root .htacces file. Isn't there a way for the .htaccess file recognize any given string within the url and strip it out? to reiterate what I want to do using the example.com protocol: For example, using the Redirect permanent command I can do this: Redirect permanent /cgibin/SoftCartexe/scstore http://www.example.com/scstore but it won't do this: Redirect permanent /cgi-bin/SoftCart.exe/scstore http://www.example.com/scstore I also tried this: Redirect permanent /cgi-bin/SoftCart\.exe/scstore http://www.example.com/scstore Apache must have some safeguard for cgi-bin and dots within a url string. I can using other hyphenated terms in the url string: Redirect permanent /try-this/scstore example.com/scstore But none that has a "." in it or "cgi-bin" Any ideas? Thanks
|
g1smd

msg:4325622 | 7:38 pm on Jun 13, 2011 (gmt 0) |
As far as I know, CGI requests are "grabbed" by the respective handler before mod_rewrite has a chance to get to them.
|
rshandy

msg:4325653 | 8:50 pm on Jun 13, 2011 (gmt 0) |
oh, that makes sense. Any easy was to rectify this? Now, its back to something the JD was referring in an old post. Can a simple script be made and called SoftCart.exe to redirect to the new url string?
|
|