Combining two columns/fields in PDO select query
<p>My PDO statement returns 3 fields of data and displays the 3 field in a 3 column table:
<a href="https://i.stack.imgur.com/uJGx5.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/uJGx5.jpg" alt="enter image description here"></a></p>

<p>I would like to adjust the code so the table displayed only has 2 columns.</p>

<p>This first column should display the country's flag instead of the name. The flag will be in the following folder <code>site_url(); ?&gt;/wp-content/gallery/Flags/'Country'.png</code>.</p>

<p>The second column should display <strong>BOTH</strong> First Name and Last Name.</p>

<pre><code>&lt;?php
//Table
echo "&lt;table style='border: solid 1px orange;'&gt;";
echo "&lt;tr&gt;&lt;th&gt;Country&lt;/th&gt;&lt;th&gt;First Name&lt;/th&gt;&lt;th&gt;Last Name&lt;/th&gt;&lt;/tr&gt;";
class TableRows extends RecursiveIteratorIterator
    {
        function __construct($it)
            {
                parent::__construct($it, self::LEAVES_ONLY);
            }

        function current()
            {
                return "&lt;td style='width:150px;border:1px solid orange;'&gt;".parent::current()."&lt;/td&gt;";
            }

        function beginChildren()
            {
                echo "&lt;tr&gt;";
            }

        function endChildren()
            {
                echo "&lt;/tr&gt;" . "\n";
            }
    }

//Connection Info
//Connection Started, Data pulled
try {
    $conn = new PDO("mysql:host=$servername;dbname=$dbname", $username, $password);
    $conn-&gt;setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
    $firstname = $_GET['fname'];
    $stmt = $conn-&gt;prepare('SELECT Country, First_Name, Last_Name FROM     tblPlayers WHERE First_Name  = :fname');
    $stmt-&gt;bindValue(':fname', $firstname, PDO::PARAM_INT);
    $stmt-&gt;execute();

    // set the resulting array to associative
    $result = $stmt-&gt;setFetchMode(PDO::FETCH_ASSOC);
    foreach(new TableRows(new RecursiveArrayIterator($stmt-&gt;fetchAll())) as $k=&gt;$v) {
        echo $v;
    }
}
//Error Check
catch(PDOException $e) {
    echo "Error: " . $e-&gt;getMessage();
}

// Take Text entry and fetch the SQL Row
//Kill Connection 
$conn = null;
echo "&lt;/table&gt;";
?&gt; 
</code></pre>

<p>Thanks for your help solving my problem.</p>