I am trying to make an update process using two livewire controller. I want to pass the id of the selected page and pass that data to another livewire controller.
I've tried to use: return redirect()->route('system-pages/update-system-page', ['pages_id' => $this->modelId]); to pass the data to the url in which the $this->modelId is the id of the page. The current URL right now whenever I select a page is http://127.0.0.1:8000/system-pages/update-system-page?pages_id=7.
I'm getting the id by converting the url into string and selecting the final character: $this->pageData = (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] === 'on' ? "https" : "http") . "://$_SERVER[HTTP_HOST]$_SERVER[REQUEST_URI]";.
Is there any better way to get the id from another component and pass that data to another livewire component? Thank you.