Support the ongoing development of Laravel.io →
Blade Laravel
Last updated by @ajax30 2 weeks ago.
0

Here is how I solved the problem, using the section of the documentation:

@if($articles->hasPages())
	<div class="clearfix">
		<ul class="pagination">
			<li class="next">
				<a class="btn btn-primary {{ $articles->onFirstPage() ? 'disabled' : '' }}" href="{{ $articles->previousPageUrl() }}">&larr; Newer Posts</a>
			</li>
			<li class="prev">
				<a class="btn btn-primary {{ $articles->onLastPage() ? 'disabled' : '' }}" href="{{ $articles->nextPageUrl() }}">Older Posts &rarr;</a>
			</li>
		</ul>
	</div>
@endif
0
Solution selected by @ajax30

Sign in to participate in this thread!

LaraJobs

Your banner here too?

Razvan Razvan ajax30 Joined 2 Oct 2021

Moderators

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

Your logo here?

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

© 2022 Laravel.io - All rights reserved.