ZenphotoCMS Forum
Single_login server issue - 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: Single_login server issue (/thread-6114.html)



Single_login server issue - annabell - 11-11-2009

Hi, not sure if anyone can help but I have used the single_login hack on a number of zenphoto installations before with no problems.

I have just completed the current install on a new serer and added the single_login.php file to the zenphoto root folder. http://fotka.com.au/zenphoto/single_login.php

Any time I try to access the link above or through the index.php file (http://fotka.com.au/index.php) I get redirected to the setup page to upgrade. This same login file and installation works well on two other servers I use.

Not sure if this is something to do with zenphoto or the server settings?

It would be great if anyone has any ideas!




Single_login server issue - annabell - 16-11-2009

Hi, me again. Just had a quick update/bump and was hoping someone could help me out, as i don't know any php.

In the single_login.php file (http://fotka.com.au/zenphoto/single_login.php) the code is redirecting the user to the /setup.php page instead of displaying the login form.

Does anyone know if there is anything I can change in the php in the single_login file so that it doesn't re-direct but displays the login form instead?




Single_login server issue - acrylian - 16-11-2009

Try this. Here change setup.php to admin.php: $location = "http://". $_SERVER['HTTP_HOST'].dirname($_SERVER['SCRIPT_NAME']) . "/" . ZENFOLDER . "/setup.php";




Single_login server issue - annabell - 17-11-2009

Hey Acrylian - thanks for the reply! If I change setup.php to admin.php it re-directs to the admin page login. http://fotka.com.au/clients/single_login.php

This is good for the main administrator but I was hoping to have the option for "clients" to login via the photo gallery interface with single_login so they don't see the admin area. I tried a clean install on another server and it seems to be having the same issue.

http://paste.com.au/clients/PHOTO/zenphoto/single_login.php

Does anyone know if single_login works with the latest version of zenphoto 1.2.6? or should I go back to version 1.2.1 which I have working well?




Single_login server issue - acrylian - 17-11-2009

Well, loggin in always leads to the admin backend. You probably have to modify the zp-core/lib-auth.php file. Sorry, I can't really help with that script as I never tried it. You can of course use 1.2.1 if that works fine for you but we won't be able to support that, too.




Single_login server issue - sbillard - 17-11-2009

if (!file_exists(dirname(__FILE__) . '/' . ZENFOLDER . "/zp-config.php")) {

needs to be changed on the current Zenphoto to

if (!file_exists(dirname(__FILE__) . '/' . DATA_FOLDER. "/zp-config.php")) {

as the config file has been moved out of the core files.




Single_login server issue - annabell - 18-11-2009

Hey Sbillard thanks for the response! I changed the line above in the single_login.php file but it is still re-directing instead of displaying the login form.