Level 24
try
{{ url('/products',[$tag]) }}
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
Hi guys, I know that this is basic question but I really want to know how to pass a PHP variable into helper {{ url() }}
<?php
$tag= 'electronics';
?>
<a href="{{ url('/products') }}">Products</a>
Thanks in advance.
Please or to participate in this conversation.