fixed the global js variable problem in GalenPages