A message is a widget with 2 elements:
Here you’ve a screenshot with the “warning” icon:
$this->build("p4a_message", "message"); // this is not necessary, the default icon is warnig // you can also set "info" or "error" $this->message->setIcon("warning"); // this is not necessary, the default value is true // but you can also turn autoClear(false) // with autoClear on the message will reset his value // after the output. $this->message->autoClear(true); // set the text $this->message->setValue("Please fill all required fields");