Problem with this function is when you have long strings (upwards of 1000+). Best way to fix this is via the use of a Stringbuilder/buffer. Below is my proposed fix:

StringBuilder result = new StringBuilder();
    StringTokenizer st = new StringTokenizer(input, " ");
    while (st.hasMoreTokens()) {
        StringBuilder thisToken = new StringBuilder(st.nextToken());
        result.append(thisToken.reverse() + " ");
    }
    String resultString = result.toString();