code refine; add footer support;