I am wondering if I can get my PHP page running because I try to load image files from the database in phpMyAdmin and on MySQL. Here is the line of code I was working on:
CREATE DATABASE WORLD;
use WORLD;
CREATE TABLE COUNTRY (
    country_Order INT AUTO_INCREMENT NOT NULL,
    continent_Name VARCHAR(225),
    country_Name VARCHAR(225),
    img BLOB,
    country_Region VARCHAR(225),
    country_Population INT,
    country_Info VARCHAR(225),
    PRIMARY KEY (country_Order)
)  ENGINE=INNODB;
INSERT INTO COUNTRY (country_Order, continent_Name, country_Name, img, country_Region, country_Population, country_Info)
VALUES (1, "Asia", "Afghanistan", LOAD_FILE('\Users\sammyabdulkader\desktop\World-Data\img\Afghanistan.png'), "Central Asia", 38928346,"Afghanistan is a country located in Central Asia. It is a mountainous landlocked country.");
I want manually insert my own images that why from my folder path. This is being done on my MacBook Pro. Here is my PHP code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN">
<html>
  <body>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>World Database</title>
        <style type="text/css">
        h1 {
            color: #42963d;
            font-family: 'Open Sans', sans-serif;
            font-size: 34px;
            font-weight: 300;
            line-height: 40px;
            margin: 0 0 16px;
            text-align: center;
        }
        h2 {
            font-family: 'Open Sans', sans-serif;
            font-weight: 300;
            text-align: center;
            color: #50d248;
        }
        p.footer {text-align: center}
        table.output {font-family: Ariel, sans-serif}
        table {
            border-collapse: collapse;
            width: 100%;
            color: #4ee44e;
            font-family: monospace;
            font-size: 25px;
            text-align: center;
        }
         th {
            background-color: #0b7208;
            color: white;
        }
        tr:nth-last-child(even) {background-origin: #f2f2f2}
         hr {
            height: 12px;
            border: 0;
            box-shadow: inset 0 12px 12px -12px rgba(0, 0, 0, 0.5);
        }
        a {
            color: red;
            font-family: helvetica;
            text-decoration: none;
            text-transform: uppercase;
        }
         a:hover {
            text-decoration: underline;
        }
        a:active {
            color: black;
        }
        a:visited {
            color: purple;
        }
        </style>
    </head>
   <body>
<?php
// Get connection
//$Conn = odbc_connect('database name','database user','database user & password');
$Conn = odbc_connect('WORLD', 'WORLD-User', 'WORLD-User+password');
// Test connection
if (!$Conn)
{
    exit("ODBC Connection Failed: " . $Conn);
}
// Create SQL statement
$SQL = "SELECT * FROM COUNTRY";
$RecordSet = odbc_exec($Conn, $SQL);
// Test existence of recordset
if (!$RecordSet)
{
    exit("SQL Statement Error: " . $SQL);
}
?>
                        <!--  Page Headers -->
    <h1>List of countries from around the global.</h1>
        <hr />
    <h2>All Country's Alphabetical Order</h2>
<?php
// Table headers 
echo "<table class='output' border='1'>
        <tr>
        <th>Country Order</th>
        <th>Continent Name</th>
        <th>country Name</th>
        <th>Country Flag</th>
        <th>Continent Region</th>
        <th>Country Population</th>
        <th>Country Info</th>
        </tr>";
// Table data
while ($RecordSetRow = odbc_fetch_array($RecordSet))
{
    echo "<tr>";
    echo "<td>" . $RecordSetRow['country_Order'] . "</td>";
    echo "<td>" . $RecordSetRow['continent_Name'] . "</td>";
    echo "<td>" . $RecordSetRow['country_Name'] . "</td>";
    echo "<td>" . $RecordSetRow['img'] . "</td>";
    echo "<td>" . $RecordSetRow['country_Region'] . "</td>";
    echo "<td>" . $RecordSetRow['country_Population'] . "</td>";
    echo "<td>" . $RecordSetRow['country_Info'] . "</td>";
    echo "</tr>";
}
echo "</table>";
// Close connection
odbc_close($Conn);
?>
        <br />
         <hr />
        <p class="footer"><a href="../World-Data/index.html">Return to World Data</a></p>
       <hr />
  </body>
</html>
My problem is that when I did the manual way, I get null values for my PHP table. The other problem is doing it on phpMyAdmin makes it look worse. Instead, it returns stranges characters.
Is there a possible way to fix my problem so that I can get my images in my database table up and running? phpMyAdmin way inserting the images from the online database Manual way from MySQL insert
 
    