fix the _createScriptTag to be able to use this so it can call _trackPag...

...es when trackPages is on, also fix the js unit tests, thanks for mentioning the unit tests I hadn't checked to see if they were still usable. This should work now, it at least passes all the js unit tests.