How to create a link with Mojolicious tag-helper url_for
which opens in a new window/tab?
The result should be HTML-Code like <a href="./intern/rba/list" target="_blank">RBA List</a>
Asked
Active
Viewed 546 times
0

lanti
- 529
- 3
- 15
1 Answers
1
%= link_to 'RBA-List' => url_for('list_rba'), target => '_blank'

lanti
- 529
- 3
- 15
-
Does this still work in the current version of Mojolicious? I've tried but had no luck. – thran Jun 24 '23 at 21:56
-
At least here it works. `$ cpanm --info Mojolicious SRI/Mojolicious-9.33.tar.gz` – lanti Jun 26 '23 at 04:59
-
Working now, I had passed it as a param to url_for and not link_to. Whoops. – thran Jun 26 '23 at 20:46