paboo's avatar

how do i change the base link pagination in laravel 5.1.6

this my Controller

 public function getHome(){
       
    $pagination= DB::table('users')->paginate(2);

               $adc = DB::table('users')
         ->join('addresss','users.id','=','addresss.user_id')
         ->join('points','users.id','=','points.user_id')
         ->select('users.*','addresss.address','points.points')->get();  
       
        return View('home',['pagination'=>$pagination])->with('adc',$adc);
    }

{!! $pagination->render() !!}
    

the link i receive

" target="_blank">http://localhost/users/action/home?page=2">

how do i add http://localhost/

reworks/public

/users/action/home?page=2

0 likes
1 reply
paboo's avatar
paboo
OP
Best Answer
Level 1
 $pagination->setPath('/reworks/public/users/action/home');

Return this link -> localhost/reworks/public/users/action/home?page=id

Please or to participate in this conversation.