Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

Thameera's avatar

why onchange function calling from blade to script is not working

''' Select a product... @foreach ($states as $service) {{ $service->name }} @endforeach ''' this is my blade but i put my function in script ''' function myfunction() { alert("hi"); }'''

but this simple function is not working

0 likes
4 replies
Thameera's avatar

i called onchange function in select form unfortunately that is not there

Thameera's avatar

This is my code in blade

Select a product...

Thameera's avatar

This is my code in javascript function myfunction() { alert("hi"); }

Please or to participate in this conversation.