XAMPP localhost redirects to localhost/dashboard

后端 未结 8 691
梦毁少年i
梦毁少年i 2021-01-12 01:50

I\'ve just installed xampp-win32-5.5.30 and in xampp control panel both Apache and mysql started without any error but I found:

1)localhost

相关标签:
8条回答
  • 2021-01-12 02:43

    This:

    header('Location: '.$uri.'/dashboard/');
    

    Performs redirect to localhost/dashboard/

    Everything works as expected, if you clear this file and put some text, like "Hello world", you should see it on http://localhost/

    0 讨论(0)
  • 2021-01-12 02:43

    In the file /Applications/XAMPP/xamppfiles/etc/httpd.conf change this:

    # Virtual hosts
    # Include etc/extra/httpd-vhosts.conf
    

    with this:

    # Virtual hosts
    Include etc/extra/httpd-vhosts.conf
    

    Then, In the file /Applications/XAMPP/xamppfiles/etc/extra/httpd-vhosts.conf add with something like this:

    <VirtualHost *:80>
        ServerName sbyc.byc.local
        ServerAlias sbyc.byc.local
        DocumentRoot "/Applications/XAMPP/xamppfiles/htdocs/byc-mineduc01-ges/app"
        <Directory "/Applications/XAMPP/xamppfiles/htdocs/byc-mineduc01-ges/app">
            Options Indexes FollowSymLinks Includes ExecCGI
            AllowOverride All
            Require all granted
        </Directory>
        ErrorLog "logs/sbyc.byc.local-error_log"
    </VirtualHost>
    
    0 讨论(0)
提交回复
热议问题