if ( isset( $actionData['request']['category'] ) && $actionData['request']['category'] ) {
$where .= " AND MI.id IN (
SELECT member_info
- FROM " . GLM_MEMBERS_PLUGIN_DB_PREFIX . "category_member_info
- WHERE category IN (" . $actionData['request']['category'] .")
+ FROM " . GLM_MEMBERS_PLUGIN_DB_PREFIX . "category_member_info M,
+ " . GLM_MEMBERS_PLUGIN_DB_PREFIX . "categories C
+ WHERE M.category IN (" . $actionData['request']['category'] .")
+ OR (C.parent IN (" . $actionData['request']['category'] .") AND M.category = C.id )
) ";
}
if ( isset( $actionData['request']['county-search'] ) && $actionData['request']['county-search'] ) {
";
}
+ // echo '<pre>'.print_r($where, true).'</pre>';
// Get a list of all cities (optionally for active members only)
$cities = $this->getList( $where, 'name' );