The links should just mirror the request? Just check you are testing it correctly. If you load the page with https://.... then the pagination links should be the same?
Nov 28, 2016
12
Level 4
Laravel pagination returns links in http and not https
I am using the ->paginate(20); function on my query but the only problem is that it will return http and not https
Eg: "next_page_url":"http://www.mysite"
I have tried to force my app to use https by adding this in AppServiceProvider
public function boot()
{
if (!\App::environment('local')) {
\URL::forceSchema('https');
}
}
So have can I force Laravel to return all links in https?
Level 122
I think the https request might be recieved as http.
Big discussion here https://laracasts.com/discuss/channels/laravel/enable-https-via-cloudflare-on-laravel-41-app
and
These might help, but I'm pretty sure thats at the root of the problem
1 like
Please or to participate in this conversation.