-1

I am trying to display a flash message that includes a link to a new incident that has been raised.

This works with the old $this->Session->setFlash(__("Incident $href has been raised.")). The link is displayed correctly in the browser and can be clicked on.

Using "Flash" the browser displays the text of the href. Is it possible to display the link correctly using Flash?

$href = '<a href="'.$incident_url.'" target="_blank">'.$incident_number.'</a>';
$this->Flash->success(__("Incident $href has been raised."));

I am using CakePHP 2.10.3.

DuaneW
  • 27
  • 1
  • 7

1 Answers1

2

Yes, you can. Create / Edit success.ctp flash template, and pass your url as params in Flash component.

Read:

Salines
  • 5,674
  • 3
  • 25
  • 50