title: If received value isset, echo input field
body: <p>I have a search form on a webpage which i will create a dynamic page from the content in putted. I have got it to work but there is another one of these forms and there is also selectable data. I want it to only show the hidden fields lines when sku, sku2, txtKeyword2 is set. Please find below what i have tried so far.</p>
  
  <pre><code>&lt;form name="frmSearch" method="get" action="&lt;?=$_SERVER['SCRIPT_NAME']?&gt;"&gt;
    &lt;table width="100%"&gt;
      &lt;tr&gt;
        &lt;th&gt;&lt;h3&gt;Search    &lt;/h3&gt;
              &lt;div class="alert-box"&gt;Insert Text for alert box&lt;/div&gt;
          &lt;input name="txtKeyword" type="text" id="txtKeyword" value="&lt;?=$_GET["txtKeyword"];?&gt;" size="40"&gt;
          &lt;?php if(isset($_GET['sku'])) echo '&lt;input type="hidden" name="sku" value="'.$_GET['sku'].'"&gt;'?&gt;
          &lt;?php if(isset($_GET['sku2'])) echo '&lt;input type="hidden" name="sku2" value="'.$_GET['sku2'].'"&gt;'?&gt;
          &lt;?php if(isset($_GET['txtKeyword2'])) echo '&lt;input type="hidden" name="txtKeyword2" value="'.$_GET['txtKeyword2'].'"&gt;'?&gt;
          &lt;input class="alert button" type="submit" value="Search"&gt;&lt;/th&gt;
      &lt;/tr&gt;
    &lt;/table&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>All i want is for it not to show the input lines if they are not set. I think i am doing right but i am not sure as i am learning php.</p>
  
  <p>I have also tried the following code which did work but it outputted the following url.</p>
  
  <pre><code>index.php?txtKeyword=giro%25skyline&amp;sku=%09%09&lt;input+type%3D
  </code></pre>
  
  <p>I know this shouldn't happen but it makes my page work but when i goto enter data in to the other search form it adds part of the input line in to the url. Here is the code that i tried:</p>
  
  <pre><code>&lt;form name="frmSearch" method="get" action="&lt;?=$_SERVER['SCRIPT_NAME']?&gt;"&gt;
    &lt;table width="100%"&gt;
      &lt;tr&gt;
        &lt;th&gt;&lt;h3&gt;Search    &lt;/h3&gt;
              &lt;div class="alert-box"&gt;Insert text for the alert box&lt;/div&gt;
          &lt;input name="txtKeyword" type="text" id="txtKeyword" value="&lt;?=$_GET["txtKeyword"];?&gt;" size="40"&gt;
          &lt;input type="hidden" name="sku" value="&lt;?php if(isset($_GET['sku'])) echo ''.$_GET['sku'].'"&gt;'?&gt;
          &lt;input type="hidden" name="txtKeyword2" value="&lt;?php if(isset($_GET['txtKeyword2'])) echo ''.$_GET['txtKeyword2'].'"&gt;'?&gt;
          &lt;input type="hidden" name="sku2" value="&lt;?php if(isset($_GET['sku2'])) echo ''.$_GET['sku2'].'"&gt;'?&gt;
          &lt;input class="alert button" type="submit" value="Search"&gt;&lt;/th&gt;
      &lt;/tr&gt;
    &lt;/table&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>I would really like to know what is going on how i can fix it.</p>
  
  <p>Thanks Ryan</p>