icecoder/ICEcoder

Any way to globally set a root starting directory?

Closed this issue · 6 comments

I've searched around and seen a few variations of what I am trying to but none that specifically answer my question.

I cloned the repo into my server document root (e.g. /home/www) which created its own folder ICEcoder. I fired up my browser and logged in just fine. But I get the top level directory to the ICEcoder installation ... which seems rather dangerous to me.
image

Is there no way to globally set the startup root to be a sub-directory of $iceRoot?

@fyrfli you may want to look in what you have set for your servers PHP 'DOCUMENT_ROOT' setting.

If you've installed ICEcoder to /home/www/ICEcoder, when you visit [yoursite]/ICEcoder you should see the dir & file contents of /home/www excluding the ICEcoder folder.

What may help is to put a PHP file (eg x.php) in both the www dir and ICEcoder dirs containing: <?php echo $_SERVER['DOCUMENT_ROOT']; and then visit [yoursite]/x.php and [yoursite]/ICEcoder/x.php to see what it shows.

Well, [yoursite] (without the subdir notation) goes directly to /home/www/ICEcoder (I use a subdomain i.e. ice.myhost.tld).

x.php (in /home/www/ICEcoder) gives me "/home/www/ICEcoder"
y.php (in /home/www) gives me "File not found"

So clearly I missed something...

Is it that ICEcoder should only be installed in a subdirectory of the site I'm working on? I think what I am missing is that I was using it as site on its own, not as a tool for developing another site. Is that where my confusion is?

That was it. ICEcoder needs to be installed in a subdirectory of the main domain. Thank you so much!!!

Yep, glad you got it @fyrfli and things working fine now.

If there's something I could tweak tho to avoid any confusion for others just LMK.

Otherwise, glad you're underway now! 👍🏼

Not sure if there is something you could tweak in this case... I think most people come with the expectation that is an extension tool for development whereas I was looking for a tool I can use to generally "play" with code. Two different use-cases. And ... if anyone else stumbles on the same issue, it's here in your issue history for them to check. 😉