 </cfif>
 <!---------------------------------------------------------------------------->
 
-<cfif action is "insertWithCollectionCode">
-	<cfquery name="d" datasource="user_login" username="#session.dbuser#" password="#decrypt(session.epw,session.sessionKey)#">
-		select * from CTATTRIBUTE_TYPE where attribute_type='#attribute_type#'
-	</cfquery>
-	<cfif d.recordcount gt 0>
-		<cfthrow message="Attribute already exists; edit to add collection types.">
-	</cfif>
-	<cfquery name="sav" datasource="user_login" username="#session.dbuser#" password="#decrypt(session.epw,session.sessionKey)#">
-		insert into CTATTRIBUTE_TYPE (
-			collection_cde,
-			attribute_type,
-			DESCRIPTION
-		) values (
-			'#collection_cde#',
-			'#attribute_type#',
-			'#description#'
-		)
-	</cfquery>
-	<cflocation url="ctattribute_type.cfm" addtoken="false">
-</cfif>
-
-
-
-
-
-
-
-
-
-
-
 
 <!---------------------------------------------------------------------------->
-<cfif action is "edit">
-	<p>
-		<a href="/Admin/CodeTableEditor.cfm">Back to table list</a>
-	</p>
-	<cfif tbl is "CTGEOLOGY_ATTRIBUTE">
-		<!----
-			<cflocation url="/info/geol_hierarchy.cfm" addtoken="false">
-			let's do this inline
-		---->
-		<cflocation url="CodeTableEditor.cfm?action=editGeologyTree">
-	<cfelseif tbl is "ctspecimen_part_name"><!---------------------------------------------------->
-		<!----<cflocation url="/Admin/ctspecimen_part_name.cfm" addtoken="false">---->
-		<cflocation url="CodeTableEditor.cfm?action=editSpecimenPart">
-
-
-	<cfelseif tbl is "CTATTRIBUTE_TYPE"><!---------------------------------------------------->
-		<cflocation url="/Admin/ctattribute_type.cfm" addtoken="false">
-	<cfelseif tbl is "ctspec_part_att_att"><!---------------------------------------------------->
-		<cflocation url="/Admin/ctspec_part_att_att.cfm" addtoken="false">
-	<cfelseif tbl is "ctmedia_license"><!---------------------------------------------------->
-		<cflocation url="/Admin/ctmedia_license.cfm" addtoken="false">
-	<cfelseif tbl is "ctattribute_code_tables"><!---------------------------------------------------->
+<cfif action is "editAttCodeTables">
+
 		<cfquery name="ctAttribute_type" datasource="user_login" username="#session.dbuser#" password="#decrypt(session.epw,session.sessionKey)#">
 			select distinct(attribute_type) from ctAttribute_type
 		</cfquery>

			</form>
		</table>

		<cfset i = 1>
		Edit
		<table id="tbl" border="1" class="">

				<cfset i = #i#+1>
			</cfloop>
		</table>
</cfif>


<!---------------------------------------------------------------------------->
<cfif action is "editTaxTrm">


Terms must be lower-case
		<hr>
		<style>
			.dragger {
