Added ACF code to functions file