Is this line of "Define" line of code correct using an Add-on domain?

Hi, Thank you for taking the time to look at this. I am trying to access the Admin folder of an Add-On domain. If you can confirm this line of code is correct (or correct), I would be very grateful:

[php]define(‘DIR_FS_CATALOG’, ‘/home/TOPLEVELDOMAIN_NAME/public_html/ADD-ON_DOMAIN.com’);[/php]

Obviously, the TOPLEVELDOMAIN_NAME and ADD-ON_DOMAIN phrases are substitutes for the real thing.

Thank you
Doug

Hi kernow01,

I know you indicated that ADD-ON_DOMAIN is a substitute for the real thing, but I wasn’t sure how you were substituting the real value. Is “ADD-ON_DOMAIN” an actual php constant that you are setting up first, or are you inserting a literal value in its place. If it represents a defined constant, I believe it will fail because of the hyphen. I would suggest something like “ADDON_DOMAIN” instead.

If you used it simply to indicate where you are putting the actual value, then the following should help you determine if this is the correct path or not:

What I would do is to create a very simple php file with the following code:[php]<?php
$dir = ‘/home/TOPLEVELDOMAIN_NAME/public_html/ADD-ON_DOMAIN.com’;
echo ‘

’;
print_r(scandir(’$dir’));[/php]

When you run the script, it will show you the contents of the directory; telling you whether it is the correct path or not.

If you don’t see the files you expect, I would suggest doing the following:

First, change the $dir assignment to: [php]$dir = ‘/’;[/php]
Run the script and look to see that “home” is in the listing. If it is, change $dir to ‘/home’ and try it again, looking for TOPLEVELDOMAIN_NAME. You will keep doing this until you find the problem.

Let me know…

jay

Sponsor our Newsletter | Privacy Policy | Terms of Service