So I had my variables all hard coded into my page like so:
$base_url = 'something';
$logo_url = 'somethingelse';
And then I went and put all these into a database for easier updating, Now I need to place them back into the config.php file so my website can use them.
I tried doing the following: (database.php includes all the connection details)
function get_identifiers() {
require_once 'database.php';
$result = mysqli_query($con,"SELECT * FROM settings");
while($row = mysqli_fetch_array($result))
{
$identifier = $row['identifier'];
$value = $row['value'];
$identifier = $value
}
mysqli_close($con);
}
But I got nothing. What can I do?