Some code cleanup before fixing the bug.
Save initial KPI data before session_context comes in

fixes #3014
Add a #iefix to all background-image: url(''s that contain two parts. This fixes IE8 404'ing when requesting these images.

fixes #1736
Merge pull request #3108 from shane-tomlinson/issue_3014_rp_api_kpi

Issue 3104 rp api kpi

@kparlante gave the r+, merging. Close #3104
Merge pull request #3112 from shane-tomlinson/issue_1736_ie8_404_grain

Fix the IE8 404 problem for background images.