Added WP functions for dynamic head population