Undefined index text input php? : <p>i want get text input value from php web file for save values to database, but text input not work with php file. And show this error:</p>

<blockquote>
  <p>Notice: Undefined index: txtUsername in C:/...... line 7
  Notice: Undefined index: txtPassword in C:/...... line 8</p>
</blockquote>

<p>my html:</p>

<pre><code>&lt;form  action="../Controller/LoginController.php"&gt;
    &lt;input type="text" id="txtUsername" /&gt;
    &lt;input type="text" id="txtPassword"  /&gt;
    &lt;input type="submit" name="btnLogin" value="login" /&gt;
&lt;/form&gt;
</code></pre>

<p>my php file:</p>

<pre><code>$strUsername = $_POST["txtUsername"];  //line 7
$strPassword = $_POST["txtPassword"];  //line 8
</code></pre>
