I'm using Laravel Datatables (https://github.com/yajra/laravel-datatables) and adding one column to every row to delete the current entry:
return Datatables:of($data)->add_column('delete', '<a href="' . URL::to('/entries/delete/' . '{{ $entry_id }}') .'" [...]')->make();
Interestingly the URL helper returns "localhost:8489" instead of the actual URL. I have absolutely no idea why it's using 8489.
Any ideas? Thanks
environment problem? .env settings wrong?
does it give you correct URL outside of that package?
Oh, forget to mention: it's laravel 4.2. Hence no .env settings.
URL is correct everywhere else. If I log URL within the AJAX call (before the return Datatables... stuff) it's also localhost:8489.
can you maybe post the AJAX call code? whole of it?
can you also dump/echo which environment you are using? ie prod or staging or local etc.. assuming your app actually DOES have different environments?
AJAX call comes directly from datatables;
$('#table').dataTable({
ordering: true,
serverSide: true,
ajax: 'data/get/'
});
App doesn't have different environments.
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community