title: PHP - How do question marks after address work?
body: <p>I've been wondering what links like <a href="http://example.com/filename.php?dosomething" rel="noreferrer">http://example.com/filename.php?dosomething</a> and <a href="http://somesite.net?logoff" rel="noreferrer">http://somesite.net?logoff</a> do.</p>
  
  <p>As I don't know much about PHP, and english isn't my native language, I've been unable to find  good information like this.  </p>
  
  <p>I know that <a href="http://mysite.com/edit.php?editpassword" rel="noreferrer">http://mysite.com/edit.php?editpassword</a> and <a href="http://mysite.com/edit.php?editname" rel="noreferrer">http://mysite.com/edit.php?editname</a> could serve totally different content, but how can I implement it?</p>
  
  <p>Let's say that I want to implement these lines of code to ?editpassword</p>
  
  <pre><code>Password
  &lt;input type="password" name="password"&gt;
  &lt;input type="submit"&gt;
  </code></pre>
  
  <p>and these lines to ?editname</p>
  
  <pre><code>Type your name
  &lt;input type="text" name="name"&gt;
  &lt;input type="submit"&gt;
  </code></pre>
  
  <p>How could I do it in a file that could contain </p>
  
  <pre><code>&lt;?php 
  require "includes/head.php"; 
  require "includes/nav.php";
  if(!isset($_SESSION['login'])){
      header("Location: index.php");
  }
  ?&gt;
  
  
  
              &lt;div class="row-fluid"&gt;
          &lt;div class="span3"&gt;
            &lt;div class="well sidebar-nav"&gt;
              &lt;ul class="nav nav-list"&gt;
              &lt;li class="nav-header"&gt;New&lt;/li&gt;
                &lt;li&gt;&lt;a href="#"&gt;sss&lt;/a&gt;&lt;/li&gt;
  
              &lt;/ul&gt;
            &lt;/div&gt;&lt;!--/.well --&gt;
          &lt;/div&gt;&lt;!--/span--&gt;
          &lt;div class="span9"&gt;
            &lt;div class="row-fluid"&gt;
              &lt;div class="span9"&gt;
                &lt;h2&gt;Some header&lt;/h2&gt;
                &lt;p&gt;Some text&lt;/p&gt;
              &lt;/div&gt;&lt;!--/span--&gt;
            &lt;/div&gt;&lt;!--/row--&gt;
            &lt;div class="row-fluid"&gt;
              ?editname &amp; ?editpassword should appear here.
        &lt;/div&gt;&lt;!--/row--&gt;
  
              &lt;?php require "includes/footer.php"; ?&gt;
  </code></pre>
  
  <p>something like that?</p>