I've searched through the forums and tried every combination suggested for retrieving the slug for my categories:
$categories = $wpdb->get_col($cat_query);
foreach ($categories as $category) {
echo '<category>'.$category.'</category>'.
//add in slug
'<slug>'.$category->slug.'</slug>';
}
...the category itself comes through fine, but the slug (I've checked a million times that its been assigned a slug of course) doesn't appear:
<?xml version="1.0" encoding="UTF-8"?>
<channel><title>GeoMashup Query</title><item><category>alcachofa de Benicarló</category><slug></slug
It's probably a stupid syntax error, but I'd really appreciate it if someone could point it out to me.