Had a system failure and reinstalled my OS, Apache and PHP. I have since changed the Apache document root from /var/www/html to /var/www/. Module rewrite is already enabled. All my projects folders have 755 permission and the browser lists them all under localhost. The projects show their home pages and I can navigate to sub pages in them which are mostly pure HTML and PHP pages. I can access the home page of Pico projects, however, navigating to other pages throws the following error.
Not Found
The requested URL was not found on this server.
Apache/2.4.38 (Debian) Server at localhost Port 80
Here's the .htaccess from one of the Pico projects.
<IfModule mod_rewrite.c>
RewriteEngine On
# May be required to access sub directories
#RewriteBase /
# Deny access to internal dirs and files by passing the URL to Pico
RewriteRule ^(config|content|vendor|CHANGELOG\.md|composer\.(json|lock|phar))(/|$) index.php [L]
RewriteRule (^\.|/\.)(?!well-known(/|$)) index.php [L]
# Enable URL rewriting
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^ index.php [L]
<IfModule mod_env.c>
# Let Pico know about available URL rewriting
SetEnv PICO_URL_REWRITING 1
</IfModule>
</IfModule>
# Prevent file browsing
Options -Indexes -MultiViews
I have since started a brand new Pico project downloaded from the Pico website that has the default demo page. The sub page in it: /?sub and /?a/very/long/url are show their respective pages. .htaccess in this project and the older projects are the same and have the same permissions.
Had a system failure and reinstalled my OS, Apache and PHP. I have since changed the Apache document root from /var/www/html to /var/www/. Module rewrite is already enabled. All my projects folders have 755 permission and the browser lists them all under localhost. The projects show their home pages and I can navigate to sub pages in them which are mostly pure HTML and PHP pages. I can access the home page of Pico projects, however, navigating to other pages throws the following error.
Here's the
.htaccess
from one of the Pico projects.Here's the part from
apache2.conf
I have since started a brand new Pico project downloaded from the Pico website that has the default demo page. The sub page in it:
/?sub
and/?a/very/long/url
are show their respective pages..htaccess
in this project and the older projects are the same and have the same permissions.