working version with greenhead Portal