2013-03-13, 20:20:52
Hi there,
I'm coding a simple Shop plugin to GS from existing shop. I'm stuck to situation where I'm trying to fetch data from db to gs plugin admin area and nothing gets printed...
Test code looks like this:
config.php is the file where the connections are made and they are ok.
Anyone who could help me with this...?
I'm coding a simple Shop plugin to GS from existing shop. I'm stuck to situation where I'm trying to fetch data from db to gs plugin admin area and nothing gets printed...
Test code looks like this:
PHP Code:
require 'plugin/config.php';
$query = "SELECT * from " . $db_database . "." . $db_table . "_category";
$result = mysqli_query($db, $query);
if (mysqli_num_rows($result)>0) {
while ($row = mysqli_fetch_assoc($result)) {
echo '<pre>';
print_r($row);
}
}
config.php is the file where the connections are made and they are ok.
Anyone who could help me with this...?