Showing 7 of 1,216 result(s)
Starting with a fresh Laravel application, we need to install two new dependencies. The first will be Volt, which will also add Livewire to our project for us: composer require livewire/volt The second dependency we will use is a Blade parser...
When use the paginator in Laravel, we get URLs like this: http://localhost:8000/users?page=1 and we want URLs like this http://localhost:8000/users/page/1 because why not? When digging through the code for the paginator class, I found that the...
…ttyPaginator class written, we actually need to use it. This will involve some more work, but its pretty simple. Here are the things we will need to do: Create a new Route for our pagination URL,, Create a function that uses our new paginator,,...
…ltiple values allowed) . A command with a signature similar to the above example could be executed like so: When the command above is issued, the firstName value would be John , the lastName value would be Doe and the array of websites would...
Let's take a look at a few examples to see how this would format a few example strings. The string returned will appear above the function call as a comment. In fact, all of the function calls below will return the string MyWords : Pascal Case...
…be bound as a singleton). The important part is that we have an service container binding: math which will resolve to an instance of Calculator . It is at this point a facade can be created. A facade is created by creating a new class and...
…tion will now contain Conference object instances instead of our previous arrays. Our particular implementation of Conference exposes a method numberOfSpeakers which simply returns the number of speakers at that particular conference instance....