Here are some code snippets that make the Desire2Learn myLibrary link work.

Sample Code to parse Course Number:

<cfset college = LEFT(#URL.CourseNum#,2)/>
<cfset program = MID(#URL.CourseNum#,3,2)/>
<cfset course = MID(#URL.CourseNum#,5,3)/>
<cfset section = MID(#URL.CourseNum#,8,2)/>
<cfset quarter = RIGHT(#URL.CourseNum#,5)/>
<cfset III_course_num = #quarter# &'-'& #college#&#program# &'-'& #course# &'-'& #section#/>
<cfset person = #URL.Role#>

SQL code to pull course reserves from III Millennium System

SELECT rec_key, iii_tag, rec_data
FROM var_fields2
WHERE rec_key IN (select link_rec
FROM link_rec2
WHERE rec_key in (select substr(REC_DATA, 1,8)
FROM var_fields2
WHERE iii_tag = '9'
AND substr(rec_data, (length(rec_data) - 2), 3) = '::a'
AND rec_key =
(SELECT rec_key
FROM var_fields2
WHERE rec_key LIKE <cfqueryparam value= "r%" cfsqltype="CF_SQL_CHAR">
AND iii_tag = 'r'
AND rec_data = '#III_course_num#')))
AND iii_tag = 't'
ORDER BY rec_data

Sample code to figure out contact info:

<!--- contact info can be determined by parsing college --->
<cfif #college# is '01'> <cfset contactinfo = 'Contact_01.html'/> <!--- COB --->
<cfelseif #college# is '03'> <cfset contactinfo = 'contact_03.html'/> <!--- COE --->
<cfelseif #college# is '05'> <cfset contactinfo = 'contact_05.html'/> <!--- CLA --->
<cfelseif #college# is '08'> <cfset contactinfo = 'contact_08.html'/> <!--- NTID --->
<cfelseif #college# is '10'> <cfset contactinfo = 'contact_10.html'/> <!--- COS --->
<cfelseif #college# is '11'> <cfset contactinfo = 'contact_11.html'/> <!--- WI ---->
<cfelseif #college# is '17'> <cfset contactinfo = 'contact_06.html'/> <!--- ACS --->
<cfelseif #college# is '40'> <cfset contactinfo = 'contact_40.html'/> <!--- CCIS --->
</cfif>

<!--- Display contact info --->
<cfinclude template=#contactinfo#/>