I'm upgrading a plugin from Omeka 1 to 2 compatability. I'm not super familiar with Omeka and I'm trying to create a dropdown list of my collections. Is there a way to get related content, as collection name appears to be in Omeka_Elements_Text table, or do I need to write a join? In Django you just keep chaining your model names together until you get the field you want? Here's what I have so far?
<select id="item_type">
<option id="">--Select Type--</option>
<?php
$item_types = get_records('ItemType', array(), -1);
set_loop_records('types', $item_types);
foreach(loop('types') as $type): ?>
<option id="<?php echo $type->id; ?>"><?php echo $type->name ?></option>
<?php endforeach; ?>
</select>