4images Forum & Community
4images Issues / Ausgaben => Discussion & Troubleshooting => Topic started by: mantra on May 20, 2005, 03:33:36 AM
-
I try running two 4images 1.7 installation with deferent site in one server [ localhost also deferent name database],
Some strange happen ,,, i log in as admin for site A is doing fine like allways but then when i log in as admin for site B then in site A when i try edit something i lost my log in [ form log in come again ] even i try log in for siteA again they can not eccept my username and password.
But when I erase all record table 4images_sessions in site A then i can log in again or edit something.
any clue for this problem ?
-
try use localhost address for site A and 127.0.0.1 for site B
the point is, u can not use same domain for two different installations of 4images, unless they are linked some how...
-
Different site (domain) and different database? That's fine even on the same server. There must be something else going on here.
Is one of these domains a "parked" domain?
For your 2 config.php files, do you have it set up so that:
Site A uses localhost and database 4images_siteA
Site B uses localhost and database 4images_siteB
Are you using two separate installations of the PHP & template files? Are you using the same MySQL user for both config.php files? If so, you MIGHT try creating a 2nd MySQL user.
We need more info to help
-
Is one of these domains a "parked" domain? => NO I try this at localhost
For your 2 config.php files, do you have it set up so that:
Site A uses localhost and database 4images_siteA => yes
Site B uses localhost and database 4images_siteB=> yes
Are you using two separate installations of the PHP & template files? => yes
Are you using the same MySQL user for both config.php files? => yes
it seem like after the second log the site B replace the cokie site A
i try change session.php in includes folder
define('COOKIE_NAME', '4images_');
with
define('COOKIE_NAME', 'Blahs_');
but still got same result :(
-
Don't edit the PHP code! This is a setup issue for sure. I just don't know enough about the details to provide an answer yet.
A "parked" domain is one that shares the same web space (file system directory location) as another domain. It has nothing to do with the name of the server box.
Instead, try to edit the includes/constants.php for each site. Locate this:
// If 4images has problems to find out the right URL, define it here.
// define('SCRIPT_URL', 'http://www.yourdomain.com/4images'); //no trailing slash
Uncomment it and set the URL to the root of 4images (where the index.php is located) Example:
// If 4images has problems to find out the right URL, define it here.
define('SCRIPT_URL', 'http://www.example.com/4images'); //no trailing slash
Also try to think about any other details regarding your web site set up. Please provide more details if you can. How about a URL to each web site? No login information, just URLs.
-
Also try to think about any other details regarding your web site set up. Please provide more details if you can. How about a URL to each web site? No login information, just URLs. =>
each site i install as default 4images no mood .
after the log for site B all page in admin for site A they promt me again login page for admin and if you put username and password
the site not let me in still the same a login page.
site A locate at http://localhost/4images
site B locate at http://localhost/4images2
and i try change at constants.php with
define('SCRIPT_URL', 'http://localhost/4images'); //no trailing slash
define('SCRIPT_URL', 'http://localhost/4images2'); //no trailing slash
no luck still the same
-
did u guys see my answer?
-
did u guys see my answer? => YES BOSS 8O
the point is, u can not use same domain for two different installations of 4images, unless they are linked some how...
but need for another way out , jan could you give me clue
-
V@no is right.
u can not use same domain for two different installations of 4images
http://localhost/4images
http://localhost/4images2
These are the same domain "localhost". You have to register a 2nd domain name like "localhost2"
-
thanks for all time you guys, :D :D
-
hmmm...I've got an idea...what if u edit these lines in includes/sessions.php of your site B
define('COOKIE_NAME', '4images_');
define('COOKIE_PATH', '/');
replace 4images_ with 4images_b_
will it work?
IMO these settings should be placed in constants.php to begin with..
-
Related topic: http://www.4homepages.de/forum/index.php?topic=8188
-
hmmm...I've got an idea...what if u edit these lines in includes/sessions.php of your site B
define('COOKIE_NAME', '4images_');
define('COOKIE_PATH', '/');
replace 4images_ with 4images_b_
will it work?
IMO these settings should be placed in constants.php to begin with..
No it doesn't work ....
-
hmmm...I've got an idea...what if u edit these lines in includes/sessions.php of your site B
define('COOKIE_NAME', '4images_');
define('COOKIE_PATH', '/');
replace 4images_ with 4images_b_
will it work?
IMO these settings should be placed in constants.php to begin with..
No it doesn't work ....
wierd, it worked for me...
here is my setup:
two installations of 4images:
http://localhost/4images1
http://localhost/4images1/4images2
the code in sessions.php of 4images1 was left default
the code in sessions.php of 4images2 was changed to:define('COOKIE_NAME', '4images2_');
define('COOKIE_PATH', '/4images2');
then I could login and stay logged at both 4images as two different members...
-
I just tested this also and can verify that it works against two CLEAN installs of 4images 1.7.1
-
I just tested this also and can verify that it works against two CLEAN installs of 4images 1.7.1
YES YES , somehow it's work fine now after the changes of session , Thanks :mrgreen: