title: .htaccess rewrite url , dont work on Form Submit
body: <p>I am working on a search display, but got some problems with the htaccess, not working the way I want it to. I got multiple rewrites on the same url and I assume thats why. But i am not sure..</p>
  
  <hr>
  
  <p><strong>UPDATE</strong>: From what I can see by testing, all the Rewrite urls work. But the form force the page over to <code>search.php?search=test</code> and not <code>search/test</code> as i want.</p>
  
  <p>So the real question is:</p>
  
  <blockquote>
    <p>How do I get form action="" to submit to search/test/ and not search.php?search=test</p>
  </blockquote>
  
  <hr>
  
  <p><strong>What i get:</strong></p>
  
  <pre><code>search.php?page=1
  search.php?type=DEFINED_TYPE&amp;search=test
  search.php?type=DEFINED_TYPE&amp;search=test&amp;page=1
  </code></pre>
  
  <p><strong>What i want:</strong></p>
  
  <pre><code>search/1
  search/DEFINED_TYPE/test
  search/DEFINED_TYPE/test/1
  </code></pre>
  
  <p><strong>Form:</strong></p>
  
  <pre><code>&lt;form action="" method="get" id="searchForm"&gt;
  
  &lt;label for="DEFINED_TYPE_radio"&gt;
      &lt;input type="radio" name="type" id="DEFINED_TYPE_radio" value="DEFINED_TYPE"&lt;?php if($_GET['type'] == 'DEFINED_TYPE') echo ' checked' ?&gt; /&gt;
      &lt;em&lt;?php if($_GET['type'] == 'DEFINED_TYPE') echo ' class="selected"' ?&gt;&gt;&lt;i class="fas fa-tags"&gt;&lt;/i&gt;Type&lt;/em&gt;
  &lt;/label&gt;
  
  &lt;div class="input"&gt;
      &lt;input type="text" placeholder="Search here..." value="&lt;?php echo isset($_GET['search']) ? htmlspecialchars($_GET['search']) : '' ?&gt;" name="search" id="searchField" autocomplete="off" autofocus&gt;
      &lt;i class="fa fa-search submit" id="submit"&gt;&lt;/i&gt;
  &lt;/div&gt;
  
  &lt;/form&gt;
  </code></pre>
  
  <p><strong>Htaccess:</strong></p>
  
  <pre><code>RewriteEngine On
  RewriteCond %{HTTPS} !on
  RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI}
  
  RewriteRule ^search$                    search.php [NC]
  RewriteRule ^search/([^/]+)$            search.php?page=$1 [NC]
  
  RewriteRule ^search/([^/]+)/([^/]+)$            search.php?type=$1&amp;search=$2 [E=ORIG_URI:/$1]
  RewriteRule ^search/([^/]+)/([^/]+)/([^/]+)?$   search.php?type=$1&amp;search=$2&amp;page=$3 [E=ORIG_URI:/$1]
  </code></pre>
  
  <p>Anyone who can spot what I do wrong?</p>