ZenphotoCMS Forum
allow installing in a sub-directory - Printable Version

+- ZenphotoCMS Forum (https://forum.zenphoto.org)
+-- Forum: Support (https://forum.zenphoto.org/forum-1.html)
+--- Forum: General support (https://forum.zenphoto.org/forum-4.html)
+--- Thread: allow installing in a sub-directory (/thread-3788.html)



allow installing in a sub-directory - testing - 2008-09-17

I installed Zenphoto on my server in a subdir named 'zenphoto'. Although installation was successful, viewing/admining the site results in many errors.


allow installing in a sub-directory - sbillard - 2008-09-18

Please review http://www.zenphoto.org/support/topic.php?id=3760.

Then if none of the resources there help you solve your problem, try to provide us with some information.


allow installing in a sub-directory - testing - 2008-09-18

Well, I tought one of the developers would easily confirm the problem which was why I did not provide more information -- my bad.

Turns out that on my server, PHP was setting $_SERVER['SCRIPT_NAME'] to '/php/php.exe' rather than what it was supposed to be: '/zenphoto/index.php'.

Once I fixed that zenphoto appears to run fine in a subdirectory.

My apologies for the false alarm.

Please consider this thread dead. Thank you.


allow installing in a sub-directory - testing - 2008-09-18

One follow-up.

I did have to change the line:

define('OFFSET_PATH', 1);

in admin.php to:

define('OFFSET_PATH', 0);

for admin.php to get the path right.


allow installing in a sub-directory - sbillard - 2008-09-18

That was not a good thing to do.


allow installing in a sub-directory - testing - 2008-09-18

maybe this thread is not dead after all...

What was not a good thing to do? Changing OFFSET_PATH to 0? It is the only way to make things work for me. And since that define is defined at the top of each admin script, and not in a single include file, I'll have to change it many times.


allow installing in a sub-directory - sbillard - 2008-09-18

Because OFFSET_PATH is used for lots of things. But, do what you wish. What you really need to fix is the results that are returned for the PHP variable __FILE__