If my memory serves me correctly, many years ago I created and published a website
on an Apache web server, whereby the public_html directory was at the same level as
the supporting directories for CSS, images, data and Javascript. Thus:-
cgi-bin
css
data
images
javascript
public_html
But as I understand it, on Apache2 if I quote example/public_html as the document root
then references to CSS etc directory entries would be outside the doc root and wouldn't
be available.
If I just have example as the document root, then the call to www.example.com isn't going to
find public_html/index.html
Is there a way to achieve what I had before or is it considered bad practice now not to have
the support directories underneath public_html?
on an Apache web server, whereby the public_html directory was at the same level as
the supporting directories for CSS, images, data and Javascript. Thus:-
cgi-bin
css
data
images
javascript
public_html
But as I understand it, on Apache2 if I quote example/public_html as the document root
then references to CSS etc directory entries would be outside the doc root and wouldn't
be available.
If I just have example as the document root, then the call to www.example.com isn't going to
find public_html/index.html
Is there a way to achieve what I had before or is it considered bad practice now not to have
the support directories underneath public_html?
Last edited:

