php assignment with different layouts