Note that there are some explanatory texts on larger screens.

plurals
  1. PO.htaccess redirect rule does not work with forward slashes on one particular rule
    primarykey
    data
    text
    <p>Do you see a problem with this rewrite? It never seems to get a match.</p> <pre><code>rewriterule ^content/([^/]+)/$ modules.php?module=$1 [L] </code></pre> <p>Here is the url to match: <a href="http://simplenexus.com/content/articles/" rel="nofollow">http://simplenexus.com/content/articles/</a></p> <p>Here is the destination: <a href="http://simplenexus.com/modules.php?module=articles" rel="nofollow">http://simplenexus.com/modules.php?module=articles</a></p> <p>Other rewriterule lines do get a match. For example, the following line works perfectly:</p> <pre><code>rewriterule ([^/]*).html$ content.php?pagename=$1 [L] </code></pre> <p>Both rewrite rules are in the same .htaccess file, and are right next to each other. What is interesitng, is the match seems to be a problem with both the slashes (/) and the group which matches anything but the slash ([^/]*).</p> <p>Another rule which works fine in the same file is:</p> <pre><code>rewriterule ^profiles/json/(.+/profile.json)$ http://app.simplenexus.com/profiles/json/$1 [R=302,L] </code></pre> <p>Here is everything in the htaccess file:</p> <pre><code>Options +FollowSymlinks rewriteengine on rewritecond %{HTTP_HOST} ^www.simplenexus.com$ [OR] rewritecond %{HTTP_HOST} ^simplenexus.com$ rewriterule ^install\.html$ http://simplenexus.com/redirect.php [R=302,L] #4de6cfc989e1b rewriterule ^profiles/json/(.+/profile.json)$ http://app.simplenexus.com/profiles/json/$1 [R=302,L] RewriteRule ^content/([^/]*)/$ http://simplenexus.com/modules.php?module=$1 [L] #rewriterule ^content/([^/]*)/$ modules.php?module=$1 [L] rewriterule ([^/]*).html$ content.php?pagename=$1 [L] #Article Manager RewriteRule article-archive/([0-9]{4})/([0-9]{1,2})$ modules.php?module=articles&amp;do=article-archive&amp;y=$1&amp;m=$2 [L] RewriteRule article-tags/([^/]*)$ modules.php?module=articles&amp;do=article-tags&amp;tagname=$1[L] RewriteRule article/([^/]*)\.html$ modules.php?module=articles&amp;do=article&amp;artname=$1 [L] RewriteRule article-category/([^/]*)/([0-9])-([0-9])\.html$ modules.php?module=articles&amp;do=article-category&amp;catname=$1&amp;pg=$2&amp;ipp=$3 RewriteRule article-category/([^/]*)\.html$ modules.php?module=articles&amp;do=article-category&amp;catname=$1 [L] RewriteRule article-search/$ modules.php?module=articles&amp;do=article-search [L] #&lt;Files *.jad&gt; ## Header set Content-Disposition attachment #&lt;/Files&gt; AddType text/vnd.sun.j2me.app-descriptor .jad AddType application/vnd.rim.cod .cod </code></pre> <p>Thanks for any insight.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload