Trigger Error handling added in php

Trigger Error handling added in php