I like to use php-include for the first time to include different partials within my static webpages. My folder structure is something like that:
-index.php
-other.php
----production
-------partials
-----------partial1.php
----public
-------images
-----------image1.png
And I want to reference the image from my partial1.php. So I try to do
<img src="../../public/images/image1.png">
but the reference doesn't work and I can add or delete as many "../" as I want, still not working. How else would I define a path to my public-folder and reference to that correctly?
/public/images/image1.pngto reference that image./images/image1.png) as reference and define anAliason the server side configuration for those requests. A ton of benefits if you decouple request paths from the actual physical layout on of the server side file heirarchy...