necm1
Member
- Jan 27, 2014
- 111
- 16
Hello people,
I have been working today on a new CMS. And suddenly get some errors, I've had ever looked, and bit edited, but it still does not work:
Warning: mysql_fetch_assoc () expects parameter 1 to be resource, string givenName in / Applications / XAMPP / xamppfiles / htdocs / customer / app / controller / config.inc.php on line 17
Warning: Illegal string offset 'cms_maintenance' in / Applications / XAMPP / xamppfiles / htdocs / customer / app / controller / config.inc.php on line 23
Config.inc.php:
So I spend the xd:
<?php echo $users_online; ?>
EIDT:
Had probably the mysql_query () had forgotten. But the problem is, he does not give me online users from.
I have been working today on a new CMS. And suddenly get some errors, I've had ever looked, and bit edited, but it still does not work:
Warning: mysql_fetch_assoc () expects parameter 1 to be resource, string givenName in / Applications / XAMPP / xamppfiles / htdocs / customer / app / controller / config.inc.php on line 17
Warning: Illegal string offset 'cms_maintenance' in / Applications / XAMPP / xamppfiles / htdocs / customer / app / controller / config.inc.php on line 23
Config.inc.php:
PHP:
<?php
/**
* Created by JetBrains PhpStorm.
* User: admin
* Date: 04.02.14
* Time: 22:34
* To change this template use File | Settings | File Templates.
*/
//Database config
$mysql_host = "localhost";
$mysql_username = "root";
$mysql_password = "eclipse";
$mysql_database = "cms";
//Hotel settings
$sitename = "Oderuz";
$shortname = "Your CMS";
$server_status = mysql_fetch_assoc("SELECT * FROM server_status");
$server_query = mysql_query($server_status);
$users_online = $server_status['users_online'];
$rooms_loaded = $server_query['rooms_loaded'];
$hotel_status = $server_query['status'];
$cms = "SELECT * cms_settings";
$maintenance = $cms['cms_maintenance'];
So I spend the xd:
<?php echo $users_online; ?>
EIDT:
Had probably the mysql_query () had forgotten. But the problem is, he does not give me online users from.