populate sessions via javascript