 		">
 	<cfelseif typ is "accnspecimens">
 		<cfset srchall="">
-
+		<cfset mtype="Accessioned Specimens">
 		<cfset sql="select
 				media_flat.media_id,
 				media_flat.preview_uri,

 .audiothumb { width:180px; }
</style>
<cfoutput>
	<cfif typ is "taxon">
		<cfset srchall="/MediaSearch.cfm?action=search&taxon_name_id=#q#">
		<cfset sql="select * from (
			   	select
			   		 media_id,

                 media_flat.descr
		">
	<cfelseif typ is "specimenLocCollEvent">
		<cfset mtype="Specimen's Locality (via shared Collecting Event)">
		<!--- media related to an event which uses the locality of the event used by a specumen ---->
        <cfset srchall="/MediaSearch.cfm?specimen_loc_event_id=#q#">
		 <cfset sql="
			 select
	          	media_flat.media_id,
	            media_flat.media_uri,
	            media_flat.mime_type,
	            media_flat.media_type,
	            media_flat.preview_uri,
				alt_text,
                license,
                media_flat.descr
      		from
		        media_flat,
		        media_relations,
		        specimen_event,
		        collecting_event ubsce,
		        collecting_event hmlce
      		where
		      specimen_event.collecting_event_id=ubsce.collecting_event_id and
		      ubsce.locality_id=hmlce.locality_id and
		      media_relations.related_primary_key=hmlce.collecting_event_id and
		      media_flat.media_id=media_relations.media_id and
		      media_relations.media_relationship like '% collecting_event' and
		      specimen_event.collection_object_id=#q#
     		group by
	        	media_flat.media_id,
	            media_flat.media_uri,
	            media_flat.mime_type,
	            media_flat.media_type,
	            media_flat.preview_uri,
	            alt_text,
	            license,
	            media_flat.descr
			">
	<cfelseif typ is "collecting_event">
		<cfset mtype="Collecting Event">
		<cfset srchall="/MediaSearch.cfm?action=search&collecting_event_id=#q#">
		<cfset sql="
		   	select
