Click here to Skip to main content
15,891,248 members

Comments by Member 13267099 (Top 2 by date)

Member 13267099 20-Jun-17 5:54am View    
Further,
I used also

$sth[$i] = $db->prepare("SELECT term_id FROM wp_term_taxonomy WHERE taxonomy='product-cat' || taxonomy='product-brand'");
$sth[$i]->execute();
$result[$i] = $sth[$i]->fetchAll();
print_r($result[$i])

and it returns me output:

Array
(
[0] => Array
(
[term_id] => 365
[0] => 365
)

[1] => Array
(
[term_id] => 369
[0] => 369
)
}

but i am unable to extract term_id of each array
Member 13267099 20-Jun-17 5:52am View    
Fatal error: Call to a member function fetchColumn() on a non-object on line 15