@php // Note: Most of this file contents were moved from front/js/custom.js to enable us to write PHP code within JavaScript code (to operate the Dynamic Filters dynamically (the second way)). This file is 'include'-ed in front/layout/layout.blade.php // Note: In order to be able to write PHP code within JavaScript code, you must write it in a .php file (a file with .php extension) (Note that this file has a '.php' extension!) (Another way to go is using an AJAX call to get the $productFilters!) // This file is 'include'-ed in front/layout/layout.blade.php // Operate the Dynamic Filters dynamically not statically (the second way) $productFilters = \App\Models\ProductsFilter::productFilters(); // Get all the (enabled/active) Filters // (Another way to go is using an AJAX call to get the $productFilters!) // dd($productFilters); @endphp