Support the ongoing development of Laravel.io →
Views Blade
Last updated 1 year ago.
0

Any ideas?

Last updated 1 year ago.
0

I stumbled upon: Asset::add('xlsupdates', 'js/xlsupdates.js'); a static call to add assets, but I'm not sure if that's done anymore in Laravel 4, might be a Laravel 3 thing, can't find it anywhere in the vendor directory.

Trying to do the same thing, for slightly different reasons, at a loss

Last updated 1 year ago.
0

Looks like I was right, this might help put you in the right direction: http://stackoverflow.com/questions/14205404/laravel-4-what-is-...

Last updated 1 year ago.
0

In Laravel 4 you can do something like this (assuming using blade)

{{ asset('link/to/path/in/public/folder/datatables.js') }}

If you are not using the Data Tables on every page it would be best to do a per page kind of thing. The way I find best to do that is add a

@section('pageScripts')

just below the global assets. Then call it like this:

@yield('pageScripts')
    {{ asset('link/to/path/in/public/folder/datatables.js') }}
@stop
Last updated 1 year ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.