We have moved our forum to GitHub Discussions. For questions about Phalcon v3/v4/v5 you can visit here and for Phalcon v6 here.

link_to with data-toggle attribute?

Hello, how can I use it?

{{ link_to("test", ""~var, ["data-toggle":"modal"]) }}

Doesn't work.



5.2k
Accepted
answer

Hi,

The correct is:

{{ link_to('test', ''~var, 'data-toggle':'modal') }}