System Path Issue - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived General Discussion (https://forum.codeigniter.com/forumdisplay.php?fid=21) +--- Thread: System Path Issue (/showthread.php?tid=39649) Pages:
1
2
|
System Path Issue - El Forum - 03-16-2011 [eluser]Matt Stein[/eluser] I'm attempting to set up one app to run on several subdomains. The CI 2.0.1 app (while rough) is already functional, and I'm attempting this setup on a MediaTemple DV4 server. Setup Core (core.example.com) -- this refers to the CI and app files that will be shared: /system/path/to/core/public_html/codeigniter /system/path/to/core/public_html/app User (a.example.com) -- this is supposed to be an easy way to utilize a subdomain and store user-specific files: /system/path/to/user/public_html/index.php Result Works fine at core, but results in error at User subdomain (PHP's is_dir() returns false, despite having a valid + accessible directory): Quote:Your system folder path does not appear to be set correctly. Please open the following file and correct this: index.php Experiments - tried relative and absolute paths: same result - tried using symlinks in User doc root: same result - tried wiping out is_dir() checks in index.php: nothing happens/blank screen even though error output is on Am I missing something or going about this all wrong? All the related issues I can find on these forums seem pretty straightforward. System Path Issue - El Forum - 03-16-2011 [eluser]InsiteFX[/eluser] 1) You need a copy of index.php in every sub-domain. 2) You need to edit every index.php to point to the locatation of the system and application folders. InsiteFX System Path Issue - El Forum - 03-16-2011 [eluser]Matt Stein[/eluser] Thanks, InsiteFX. Unfortunately that's exactly what I've done. I've already tried various values for the subdomain's $system_path and $application_folder vars, as mentioned above in 'Experiments'. System Path Issue - El Forum - 03-16-2011 [eluser]InsiteFX[/eluser] Did you read managing your applications in the CodeIgniter User Guide? InsiteFX System Path Issue - El Forum - 03-16-2011 [eluser]Matt Stein[/eluser] I did, and thought it to be partly irrelevant since I don't actually want to run multiple applications. I had previously separated the application folder from the 'system' folder, so I'd already been into index.php for that. (I used the full server path as instructed, and also tried a relative path just for the hell of it; neither worked.) It seems very clear that I should only have to change $system_path and $application_folder in each subdomain's index.php file, but it's just not working. System Path Issue - El Forum - 03-16-2011 [eluser]bubbafoley[/eluser] are you using absolute server paths? edit: just saw that you already said you tried it. System Path Issue - El Forum - 03-16-2011 [eluser]Joseph Wensley[/eluser] I think subdomains in Plesk are owned by a seperate user, so it may be a permissions issue. System Path Issue - El Forum - 03-16-2011 [eluser]Matt Stein[/eluser] Quote:I think subdomains in Plesk are owned by a seperate user, so it may be a permissions issue. Each folder shares the exact same owner and group. Exact same permissions (755) on each index.php as well. System Path Issue - El Forum - 03-17-2011 [eluser]InsiteFX[/eluser] Well your problem is that application/config is setting your base_url so it will only work on one directory! InsiteFX System Path Issue - El Forum - 03-17-2011 [eluser]Matt Stein[/eluser] I also considered this, but I don't think it's the issue either. From the app's config.php: Code: $config['base_url'] = "http://".$_SERVER['HTTP_HOST']."/"; |