title: Redirect everything inside subdirectory but not subdirectory itself
body: <p>I have a multilingual wordpress site that went live and replaces the old site.</p>
  <p>Not every language is translated yet, so I want to keep the old site alongside wordpress for the other languages.</p>
  <ul>
  <li><code>example.de</code> -&gt; new wordpress site</li>
  <li><code>example.de/zh-hans/*</code> -&gt; redirect to <code>example.de/cn/</code></li>
  <li><code>example.de/zh-hans/</code> -&gt; redirect to <code>example.de/cn/</code></li>
  <li><code>example.de/en/*</code> -&gt; redirect to <code>example.de/en/</code></li>
  <li><code>example.de/en/</code> -&gt; just stay on <code>example.de/en/</code></li>
  </ul>
  <p>My .htaccess looks like this at the moment:</p>
  <pre><code>Redirect 302 /zh-hans/ /cn/
  RedirectMatch 302 ^/(zh-hans)/. /cn/
  Redirect 302 /ja/ /jp/
  RedirectMatch 302 ^/(ja)/. /jp/
  RedirectMatch 302 ^/(en)/. /en/
  
  # BEGIN WordPress
  &lt;IfModule mod_rewrite.c&gt;
  RewriteEngine On
  RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
  RewriteBase /
  RewriteRule ^index\.php$ - [L]
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteRule . /index.php [L]
  &lt;/IfModule&gt;
  # END WordPress
  </code></pre>
  <p><code>en</code>, <code>jp</code> and <code>cn</code> are actual folders with index.html files in them. WordPress uses <code>en</code>, <code>ja</code> and <code>zh-hans</code> for these languages.</p>
  <p>I have some problems with this:</p>
  <ol>
  <li>Only <code>example.de/ja/</code> and <code>example.de/zh-hans/</code> are working as intended</li>
  <li><code>example.de/ja</code> (without ending slash) and all other language paths like that just redirect to <code>example.de/</code></li>
  <li><code>example.de/en</code>, <code>example.de/en/</code> end up in a redirect loop</li>
  <li>everything that comes after and ending slash (<code>example.de/ja/some-path</code>) is opened by wordpress with a 404-page</li>
  </ol>
  <p>At this point I have no idea how to handle this and I've tried different combinations for hours.</p>
  <p>Is there even a way to handle this via .htaccess?</p>