asp-classicplesk

ASP classic include files in parent directory with plesk on godaddy


I know that you need to enable parent paths in order to include files in a parent directory, however I have no way of enabling this property on godaddy's plesk hosting. Is there any way around this or do I just need to upload the include files into each and every directory on my site.

The idea of the include files was that I would have less that needed maintaining, and if I need to upload them into every folder then I certainly don't have less to maintain.

Thank you for the help.


Solution

  • You can include files that are "higher up" in the folder hierarchy, you just can't use the file="../../" syntax. Instead, use "virtual" instead of "file" and specify the full path relative to the site's root:

    <!-- #include virtual="/path/to/includes/filename.inc" -->
    

    This has the added advantage of always being the same path, regardless of where you're including it, so you can copy & paste to your heart's content.

    Of course, this will require editing every page that has includes in it, but since you were going to do that anyway, I gather this is not an issue.