added the dynamic sidebar functions and sidebar json