Examining a string of characters
Posted on 2011-03-17
This should be a pretty easy one for a ColdFusion guru...
I'm trying to examine a string of characters (a file name) to determine the file type. However, I need it to search for the first three characters after the first "." in the string, not necessarily the last three characters overall. This is because of a secondary process that thinks that any characters after the period constitute the extension. For example, if I have a file called "movement_I.prelude.mp3" I need to ultimately add logic that does NOT treat this as a .mp3 file. So what would be the coldfusion command to examine this string to look for the first three characters after the first "." (to see if they EQ "mp3")?