将Laravel应用程序部署到共享主机后,错误的分页链接

I used ajax to Load pagination content in its frame. Everything was OK in Local host. For example in http://localhost:8000/exampleroute pagination link for comments section , page 2 is: http://localhost:8000/content/page_comments?page=2 and works well.

But in shared host is: https://example.com/content/page_comments?%2Fexampleroute=&page=2 and links not work. I guess the problem is related to .htaccess file. so .htaccess contents here:

<IfModule mod_rewrite.c>
  RewriteEngine On
  RewriteBase /
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteRule ^(.*)$ index.php?/$1 [L]
</IfModule>
<IfModule !mod_rewrite.c>
  ErrorDocument 404 /index.php
</IfModule>

What is base problem?

RewriteBase / seems like it could be the issue.

Remove it and compare against https://laravel.com/docs/5.6/installation#pretty-urls. Make sure in your .env file you have APP_URL value set to your application url.