You can easily treat this line as a space-delimited list and make a friendlier line. Since arrays are faster than lists, I get them into the array as quickly as possible, and then work with it.
public string function getSaneTwitterDate(strDateIn) output="false"{ var arrOrigDate = listToArray(strDateIn, ' '); var strNewDate = arrOrigDate[2] & ' ' & arrOrigDate[3] & ' ' & arrOrigDate[6]; return dateFormat(strNewDate, 'yyyy-mm-dd'); }
This does not take into account the time offset or includes time information, but it would be easy to add.
source share