Got the look ahead working more or less... It could be done better in an...

...gular instead of a document ready function, but that will happen later.