title: Creating Border in PHP around text
body: <p>I am trying to make a printable form where the information is pulled from a mysql database using php, and I want to make a boarder around some of the text in the form, but I have tried to use</p>
  
  <p><code>&lt;div "style="border: 5px solid #aaa;"&gt; &lt;/div&gt;</code> But It comes up with a syntax error <code>Unexpected "&lt;"</code> </p>
  
  <p>and I have tried to use </p>
  
  <pre><code>p.two {
      border-style: solid;
      border-width: medium;
  }
  </code></pre>
  
  <p>Then put this at the start of the echo</p>
  
  <pre><code>&lt;p class="two"&gt;
  </code></pre>
  
  <p>But this did not work either. Here is my full code as it currently stands;</p>
  
  <pre><code>&lt;!DOCTYPE html&gt;
  &lt;html&gt;
  &lt;head&gt;
  &lt;style&gt;
  
  p.one {
      border-style: solid;
      border-width: 5px;
  }
  
  p.two {
      border-style: solid;
      border-width: medium;
  }
  
  &lt;/style&gt;
  
  &lt;body&gt;
  
  &lt;p class="two"&gt;
      &lt;strong&gt;&lt;u&gt;&lt;center&gt;&lt;font size="10"&gt;Asset Form&lt;/font size="10"&gt;&lt;/center&gt;&lt;/u&gt;&lt;/strong&gt;
  &lt;/p&gt;
  
  
  &lt;?php
  
  
  $servername = "localhost";
  $username = "appuser1";
  $password = "******";
  $dbname = "acmefg_app";
  
  
  // Create connection
  $conn = new mysqli($servername, $username, $password, $dbname);
  // Check connection
  if ($conn-&gt;connect_error) {
       die("Connection failed: " . $conn-&gt;connect_error);
  } 
  
  $sql = "SELECT id, jobnumber, assetnumber, serialnumber, make, model, description, refrigeranttype, refrigerantqty, itemcondition, installdate, location, comments, maintcomp FROM appdata";
  $result = $conn-&gt;query($sql);
  
  if ($result-&gt;num_rows &gt; 0) {
       // output data of each row
  
  
       $row = $result-&gt;fetch_assoc();
           echo "&lt;br&gt; ID: ". $row["id"].  "&lt;br&gt;";
           echo "&lt;br&gt; Job number: ". $row["jobnumber"]. "&lt;br&gt;";
           echo "&lt;br&gt; Asset number: " . $row["assetnumber"] . "&lt;br&gt;";
           echo "&lt;br&gt; Serial Number: " . $row["serialnumber"] . "&lt;br&gt;";
           echo "&lt;br&gt; Make: " . $row["make"] . "&lt;br&gt;";
           echo "&lt;br&gt; Model: " . $row["model"] . "&lt;br&gt;";
           echo "&lt;br&gt; Description: " . $row["description"] . "&lt;br&gt;";
           echo "&lt;br&gt; refrigeranttype: " . $row["refrigeranttype"] . "&lt;br&gt;";
           echo "&lt;br&gt; refrigerantqty: " . $row["refrigerantqty"] . "&lt;br&gt;";
           echo "&lt;br&gt; itemcondition: " . $row["itemcondition"] . "&lt;br&gt;";
           echo "&lt;br&gt; installdate: " . $row["installdate"] . "&lt;br&gt;";
           echo "&lt;br&gt; location: " . $row["location"] . "&lt;br&gt;";
           echo "&lt;br&gt; comments: " . $row["comments"] . "&lt;br&gt;";
           echo "&lt;br&gt; maintcomp: " . $row["maintcomp"] . "&lt;br&gt;";
       }
  
  
  $conn-&gt;close();
  ?&gt; 
  
  
  
  
  
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>I want everything that is in this section;</p>
  
  <pre><code> $row = $result-&gt;fetch_assoc();
           echo "&lt;br&gt; ID: ". $row["id"].  "&lt;br&gt;";
           echo "&lt;br&gt; Job number: ". $row["jobnumber"]. "&lt;br&gt;";
           echo "&lt;br&gt; Asset number: " . $row["assetnumber"] . "&lt;br&gt;";
           echo "&lt;br&gt; Serial Number: " . $row["serialnumber"] . "&lt;br&gt;";
           echo "&lt;br&gt; Make: " . $row["make"] . "&lt;br&gt;";
           echo "&lt;br&gt; Model: " . $row["model"] . "&lt;br&gt;";
           echo "&lt;br&gt; Description: " . $row["description"] . "&lt;br&gt;";
           echo "&lt;br&gt; refrigeranttype: " . $row["refrigeranttype"] . "&lt;br&gt;";
           echo "&lt;br&gt; refrigerantqty: " . $row["refrigerantqty"] . "&lt;br&gt;";
           echo "&lt;br&gt; itemcondition: " . $row["itemcondition"] . "&lt;br&gt;";
           echo "&lt;br&gt; installdate: " . $row["installdate"] . "&lt;br&gt;";
           echo "&lt;br&gt; location: " . $row["location"] . "&lt;br&gt;";
           echo "&lt;br&gt; comments: " . $row["comments"] . "&lt;br&gt;";
           echo "&lt;br&gt; maintcomp: " . $row["maintcomp"] . "&lt;br&gt;";
       }
  </code></pre>
  
  <p>To be contained in a the border.
  Could someone please help me work out how to do this?</p>