Make copyright/license consistent in plugin php

And add defined or die where missing.