*scratches his head*
Ok.. I kind of get this... I'll have to mull it over so I can see what
you are doing... Thanks.
s. isaac dealey wrote:
> Phillip Vector wrote:
>> Besides doing a query within a query.. Is there any other way I can
>> sort the output of cfpop so that my newest mail is at the top instead
>> of the bottom?
>
> Just because I'm in the mood to be silly.
>
> <cfscript>
> /**
> * Reverses the order of elements in a one-dimensional array.
> *
> * @param InArray One-dimensional array to be reversed.
> * @return Returna a new one dimensional array.
> * @author Raymond Simmons ([EMAIL PROTECTED])
> * @version 1.0, October 9, 2001
> */
> function ArrayReverse(inArray){
> var outArray = ArrayNew(1);
> var i=0;
> var j = 1;
> for (i=ArrayLen(inArray);i GT 0;i=i-1){
> outArray[j] = inArray[i];
> j = j + 1;
> }
> return outArray;
> }
> </cfscript>
>
> <cffunction name="QueryReverse" output="false">
> <cfargument name="Query" type="Query" required="true" />
> <cfset var column = "" />
> <cfset var data = "" />
> <cfset var qNew = QueryNew("") />
>
> <cfloop index="column" list="#Query.columnlist#">
> <cfset data = ArrayReverse(Query["#column#"]) />
> <cfset QueryAddColumn(qNew,column,data) />
> </cfloop>
>
> <cfreturn qNew />
> </cffunction>
>
> p.s. may be time to upgrade your server. ;)
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k
Archive:
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:307030
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4