05-07-2009 12:50 PM
02-07-2011 08:03 PM
<cfset application.alfrescoRoot="http://127.0.0.1:8080/alfresco'/>
<cfset application.alfrescoUsername="admin"/>
<cfset application.alfrescoPassword="admin"/>
<cfset application.logfile="alf_log"/>
<cffunction name="getTicket" returntype="string">
<cftry>
<cfhttp url="#APPLICATION.alfrescoRoot#/service/api/login?u=#APPLICATION.alfrescoUsername#&pw=#APPLICATION.alfrescoPassword#" method="GET">
<cfdump var="#XmlParse(Trim(cfhttp.FileContent))#">
<cfscript>
xmlTicketResponse = XmlParse(Trim(cfhttp.FileContent));
ticket = xmlTicketResponse.ticket.xmlText;
return ticket;
</cfscript>
<cfcatch type="any">
<cfset message = "components.titlemanager.alfresco.getTicket() failed.">
<cflog application="false" file="#APPLICATION.logfile#" type="error" text="#message#">
</cfcatch>
</cftry>
</cffunction>
<cfdump var="#getTicket()#"/>
Tags
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.