Källspråk: Engelska
First of all we are declaring 3 variables. Two of them are strings (rvsString and rvsWrdStr) and the other is an array. ‘rvsString’ will hold the reversed string, rvsWrdStr will hold the reversed word string and wrdArr will hold each word.
We are using an onEnterFrame function so that everytime the frame is entered the script inbetween the curly braces is run. ‘rvsString’ is made equal to blank because otherwise you would end up with something like TThThiThisThis etc. We then make a for loop where i is equal to the length of the input text.